Update deploy script for Gatsby deploy (#2944)
Knock on wood, that deploy went remarkably well. 👔
This commit is contained in:
8
Makefile
8
Makefile
@@ -25,8 +25,8 @@ prepare-server-deploy: website
|
||||
rm -rf ${SERVER_TMP}
|
||||
git worktree prune
|
||||
git worktree add -B ${WORKING_BRANCH} ${SERVER_TMP}
|
||||
cp -r build ${SERVER_TMP}
|
||||
git -C ${SERVER_TMP} add -f build/
|
||||
cp -r public ${SERVER_TMP}
|
||||
git -C ${SERVER_TMP} add -f public/
|
||||
git -C ${SERVER_TMP} commit --no-verify -m '[DEPLOY] Add frontend for debugging'
|
||||
cp config/local-shields-io-production.yml ${SERVER_TMP}/config/
|
||||
git -C ${SERVER_TMP} add -f config/local-shields-io-production.yml
|
||||
@@ -49,13 +49,11 @@ deploy-gh-pages:
|
||||
rm -rf ${FRONTEND_TMP}
|
||||
git worktree prune
|
||||
GATSBY_BASE_URL=https://img.shields.io \
|
||||
NEXT_ASSET_PREFIX=https://shields.io \
|
||||
npm run build
|
||||
git worktree add -B gh-pages ${FRONTEND_TMP}
|
||||
git -C ${FRONTEND_TMP} ls-files | xargs git -C ${FRONTEND_TMP} rm
|
||||
git -C ${FRONTEND_TMP} commit --no-verify -m '[DEPLOY] Completely clean the index'
|
||||
cp -r build/* ${FRONTEND_TMP}
|
||||
cp favicon.png ${FRONTEND_TMP}
|
||||
cp -r public/* ${FRONTEND_TMP}
|
||||
echo shields.io > ${FRONTEND_TMP}/CNAME
|
||||
touch ${FRONTEND_TMP}/.nojekyll
|
||||
git -C ${FRONTEND_TMP} add .
|
||||
|
||||
Reference in New Issue
Block a user