-
-
Save testfailed/8a1950a51005c1b2406daada1e4302a1 to your computer and use it in GitHub Desktop.
Revisions
-
testfailed revised this gist
Feb 26, 2022 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -26,3 +26,5 @@ function deploy() { echo "Deploy done!" # make sure `next.config.js` it set `distDir: process.env.BUILD_DIR` } deploy "$@" -
testfailed revised this gist
Feb 26, 2022 . 2 changed files with 28 additions and 25 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,28 @@ #!/usr/bin/env bash # set -euo pipefail # IFS=$'\n\t' function deploy() { # zero downtime deployment nextjs without vercel echo "Deploy starting..." git pull yarn install || exit BUILD_DIR=temp yarn build || exit if [ ! -d "temp" ]; then echo '\033[31m directory "temp" does not exists!\033[0m' exit 1; fi rm -rf .next mv temp .next pm2 reload ecosystem.config.production.js --update-env echo "Deploy done!" # make sure `next.config.js` it set `distDir: process.env.BUILD_DIR` } This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,25 +0,0 @@ -
Kamleshpaul revised this gist
Jan 24, 2022 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -18,7 +18,7 @@ rm -rf .next mv temp .next pm2 reload app --update-env echo "Deploy done." -
Kamleshpaul revised this gist
Jan 23, 2022 . 1 changed file with 8 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -4,9 +4,15 @@ echo "Deploy starting..." git pull npm install || exit BUILD_DIR=temp npm run build || exit if [ ! -d "temp" ]; then echo '\033[31m temp Directory not exists!\033[0m' exit 1; fi rm -rf .next -
Kamleshpaul revised this gist
Dec 28, 2021 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ #zero downtime deployment nextjs without vercel echo "Deploy starting..." -
Kamleshpaul revised this gist
Dec 28, 2021 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,5 @@ #zero downtime deployment on pm2 echo "Deploy starting..." git pull -
Kamleshpaul created this gist
Dec 28, 2021 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,17 @@ echo "Deploy starting..." git pull npm install BUILD_DIR=temp npm run build rm -rf .next mv temp .next pm2 reload app echo "Deploy done." #make sure `next.config.js` it set `distDir: process.env.BUILD_DIR`