Files
LiveCartaWP/Jenkinsfile

25 lines
675 B
Groovy

pipeline {
agent any
parameters {
choice(
name: 'ENVIRONMENT',
choices: ['dev', 'qa', 'new_prod', 'demo'],
description: 'Environment Name for the application (e.g., dev, production etc.)'
)
}
environment {
// LC_IMG_TAG = "${mapBranchToEnv(env.BRANCH_NAME)}"
LC_IMG_TAG = 'qa_test'
}
stages {
stage('Build') {
steps {
sh "docker build --build-arg ENV_NAME=${params.ENVIRONMENT} -t ${env.PUSH_REGISTRY}/${LC_WP_IMG}:${LC_IMG_TAG} ."
sh 'docker push ${env.PUSH_REGISTRY}/${LC_WP_IMG}:${LC_IMG_TAG}'
}
}
}
}