1
0
mirror of https://github.com/dokku/buildpack-nginx.git synced 2024-12-27 06:15:25 +00:00
buildpack-nginx/bin/ci-pre-deploy

29 lines
1009 B
Plaintext
Raw Permalink Normal View History

#!/bin/sh -l
if [ "$IS_REVIEW_APP" = "true" ]; then
git config --global user.name 'Dokku Bot'
git config --global user.email no-reply@dokku.com
2022-09-10 22:02:11 +00:00
echo "-----> Purging repo cache"
ssh "$SSH_REMOTE" -- repo:purge-cache "$APP_NAME"
echo "-----> Setting the test domain name"
2022-09-10 22:09:06 +00:00
ssh "$SSH_REMOTE" -- domains:set "$APP_NAME" "$APP_NAME.dokku.net"
echo "-----> Ensure test includes vendored app-nginx.conf.sigil"
cp conf/app-nginx.conf.sigil app-nginx.conf.sigil
git add app-nginx.conf.sigil
git commit -qm "feat: specify custom app-nginx.conf.sigil"
echo "-----> Ensure test includes vendored mime.types"
cp conf/mime.types mime.types
git add mime.types
git commit -qm "feat: specify custom mime.types"
2022-09-11 00:14:49 +00:00
echo "-----> Setting the buildpack to the current ref $GITHUB_HEAD_REF"
echo "https://github.com/${GITHUB_REPOSITORY}.git#$GITHUB_HEAD_REF" > .buildpacks
git add .buildpacks
2022-09-10 21:58:38 +00:00
git commit -qm "feat: specify $GITHUB_SHA as buildpack"
2022-09-10 23:58:50 +00:00
git rev-parse HEAD >ci-commit-override
2022-09-11 00:20:44 +00:00
fi