Update Jenkinsfile
This commit is contained in:
12
Jenkinsfile
vendored
12
Jenkinsfile
vendored
@@ -2,10 +2,6 @@ def gv
|
|||||||
|
|
||||||
pipeline {
|
pipeline {
|
||||||
agent any
|
agent any
|
||||||
parameters {
|
|
||||||
choice(name: 'VERSION', choices: ['1.1.0', '1.2.0', '1.3.0'], description: '')
|
|
||||||
booleanParam(name: 'executeTests', defaultValue: true, description: '')
|
|
||||||
}
|
|
||||||
stages {
|
stages {
|
||||||
stage("init") {
|
stage("init") {
|
||||||
steps {
|
steps {
|
||||||
@@ -22,11 +18,6 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage("test") {
|
stage("test") {
|
||||||
when {
|
|
||||||
expression {
|
|
||||||
params.executeTests
|
|
||||||
}
|
|
||||||
}
|
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
gv.testApp()
|
gv.testApp()
|
||||||
@@ -36,10 +27,7 @@ pipeline {
|
|||||||
stage("deploy") {
|
stage("deploy") {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
env.ENV = input message: "Select the environment to deploy to", ok: "Done", parameters: [choice(name: 'ONE', choices: ['dev', 'staging', 'prod'], description: '')]
|
|
||||||
|
|
||||||
gv.deployApp()
|
gv.deployApp()
|
||||||
echo "Deploying to ${ENV}"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user