update jenkins
This commit is contained in:
6
Jenkinsfile
vendored
6
Jenkinsfile
vendored
@@ -58,6 +58,8 @@ pipeline {
|
||||
set -e
|
||||
cd ${env.DEPLOY_PATH} || mkdir -p ${env.DEPLOY_PATH} && cd ${env.DEPLOY_PATH}
|
||||
|
||||
if [ -f .env ]; then cp .env /tmp/.seasoned_env_bak; fi
|
||||
|
||||
# Clone or pull the repo (contains docker-compose.yml)
|
||||
if [ -d .git ]; then
|
||||
git fetch origin
|
||||
@@ -66,6 +68,10 @@ pipeline {
|
||||
git clone ${env.GIT_REPO_URL} .
|
||||
fi
|
||||
|
||||
if [ -f /tmp/.seasoned_env_bak ]; then mv /tmp/.seasoned_env_bak .env; fi
|
||||
|
||||
if [ ! -f .env ]; then echo "WARNING: .env file is missing on server!"; fi
|
||||
|
||||
# Set the image tag for this deployment
|
||||
export IMAGE_TAG=${env.IMAGE_TAG}
|
||||
export DOCKER_REGISTRY=${env.DOCKER_REGISTRY}
|
||||
|
||||
Reference in New Issue
Block a user