Skip to content

Instantly share code, notes, and snippets.

@ijpatricio
ijpatricio / Dockerfile
Last active May 15, 2024 11:44
Build ARM Images in GitHub Actions
# more stages...
# When using a Node image, make sure to use the amd64 version, or it will take forever
# GH Actions is running arm64 in a emulator (QEMU). This way, it will use the native amd64 and be much faster.
FROM --platform=linux/amd64 node:19 as static-assets
WORKDIR /app
COPY . .
RUN npm install ; npm run build
# more stages...
@ijpatricio
ijpatricio / gist:423f02e94655e2164a1fd39930a35a41
Last active March 31, 2023 14:45
Odisseia Web com Laravel
## Odisseia Web com Laravel: Uma Jornada pelo Desenvolvimento Full Stack Web
**Instrutor**: Patricio
**Redes Sociais**:
* Youtube https://www.youtube.com/@PatricioOnCode
* Twitter https://twitter.com/ijpatricio
**Motivação**: Qualquer pessoa deve ter acesso à oportunidade de poder crescer em todos os níveis, com as tecnologias de vanguarda.
@ijpatricio
ijpatricio / Envoy.blade.php
Created February 11, 2018 12:35 — forked from freekmurze/Envoy.blade.php
Multi server zero downtime Envoy script
@setup
require __DIR__.'/vendor/autoload.php';
(new \Dotenv\Dotenv(__DIR__, '.env'))->load();
$appName = "my-app.com";
$repository = "spatie/{$appName}";
$baseDir = "/home/forge/{$appName}";
$releasesDir = "{$baseDir}/releases";
$currentDir = "{$baseDir}/current";
$newReleaseName = date('Ymd-His');