Skip to content

Instantly share code, notes, and snippets.

@slide
Created February 4, 2020 17:29
Show Gist options
  • Save slide/7f2f3e3fe3695803f27fd4a4f6669945 to your computer and use it in GitHub Desktop.
Save slide/7f2f3e3fe3695803f27fd4a4f6669945 to your computer and use it in GitHub Desktop.
def SERVICE = ""
pipeline {
agent any
stages {
stage("Web UI - Choose service") {
steps {
script {
def service = input(
message: 'Select the packages you\'d like to deploy',
parameters: [
choice(choices: ["bla", "foo", "bar"], description: '', name: 'Coronerd'),
choice(choices: ["bla", "foo", "bar"], description: '', name: 'Symbold')]
)
SERVICE = service
}
}
}
stage ("test printing version") {
steps {
echo "Coronerd package is: ${SERVICE['Coronerd']}"
echo "Symbold package is: ${SERVICE['Symbold']}"
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment