This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
steps: | |
- name: 'gcr.io/cloud-builders/docker' | |
entrypoint: 'bash' | |
args: | |
- -c | |
- | | |
docker build -t XXXXXX-docker.pkg.dev/project/image-registry/image-name -f dockerfile.prod --platform=linux/amd64 --build-arg ORDERS_DATABASE_URL=$$DATABASE_URL . | |
secretEnv: ['DATABASE_URL'] | |
- name: 'gcr.io/cloud-builders/docker' |
- Crear un nuevo repositorio en GitHub
- Clonar el repositorio en la máquina local
- Añadir el submodule, donde
repository_url
es la url del repositorio ydirectory_name
es el nombre de la carpeta donde quieres que se guarde el sub-módulo (no debe de existir en el proyecto)
git submodule add <repository_url> <directory_name>
- Añadir los cambios al repositorio (git add, git commit, git push)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
steps: | |
- name: "gcr.io/cloud-builders/docker" | |
args: | |
[ | |
"build", | |
"-t", | |
"XXXXX-docker.pkg.dev/project-name/registry/image-name", | |
"-f", | |
"dockerfile.prod", | |
"--platform=linux/amd64", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Web-Push | |
// Public base64 to Uint | |
function urlBase64ToUint8Array(base64String) { | |
var padding = '='.repeat((4 - base64String.length % 4) % 4); | |
var base64 = (base64String + padding) | |
.replace(/\-/g, '+') | |
.replace(/_/g, '/'); | |
var rawData = window.atob(base64); | |
var outputArray = new Uint8Array(rawData.length); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
openssl req -x509 -sha256 -nodes -days 365 -newkey rsa:2048 -keyout server.key -out server.crt | |
Más información - Docs Oficiales
- Instalar TypeScript y tipos de Node, como dependencia de desarrollo
npm i -D typescript @types/node
- Inicializar el archivo de configuración de TypeScript ( Se puede configurar al gusto)
git config --global alias.lg "log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all"
git config --global alias.s status --short
git config --global alias.s status -sb
NewerOlder