From 833dd401b3514393fac0bf17b18aa2f73de848d5 Mon Sep 17 00:00:00 2001 From: Nana Janashia Date: Sat, 31 Oct 2020 15:27:05 +0000 Subject: [PATCH] Add new file --- Jenkinsfile | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 Jenkinsfile diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..8a5b394 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,43 @@ +pipeline { + agent none + stages { + stage('Select micro services') { + input { + message "Select all micro services to deploy" + ok "All selected!" + parameters { + choice(name: 'MS1', choices: ['1.1.0', '1.2.0', '1.3.0'], description: 'input ms') + choice(name: 'MS2', choices: ['1.1.0', '1.2.0', '1.3.0'], description: 'input ms') + choice(name: 'MS3', choices: ['1.1.0', '1.2.0', '1.3.0'], description: 'input ms') + choice(name: 'MS4', choices: ['1.1.0', '1.2.0', '1.3.0'], description: 'input ms') + } + } + steps { + script { + echo "Hello, ${MS1}. Hello, ${MS2}. Hello, ${MS3}. Hello, ${MS4}" + MS1_TO_DEPLOY = MS1 + MS2_TO_DEPLOY = MS2 + env.MS3_TO_DEPLOY = MS3 + env.MS4_TO_DEPLOY = MS4 + } + } + } + stage('Select single service') { + input { + message "Select single micro services to deploy?" + parameters { + choice(name: 'MS5', choices: ['1.1.0', '1.2.0', '1.3.0'], description: 'second param with single option') + } + } + steps { + script { + echo "Hello, ${MS5}." + env.MS5_TO_DEPLOY = MS5 + echo "${MS1_TO_DEPLOY}" + echo "${MS4_TO_DEPLOY}" + echo "${MS5_TO_DEPLOY}" + } + } + } + } +}