Add swarm-deploy-cicd job under JJB
Add DIST_UPGRADE_NODES option to swarm-deploy-cicd
PROD-35057
Change-Id: I00e36a7987f0248724124f32a803aaeb9ad72d84
diff --git a/jobs/project.yaml b/jobs/project.yaml
index 621ad9e..84dd470 100644
--- a/jobs/project.yaml
+++ b/jobs/project.yaml
@@ -26,6 +26,8 @@
# - show_networks_used_by_libvirt - can't moved to JJB, node parameter is not supported
- maintenance-heat-cicd-pike-dvr-sl
- download-config-drive
+ - swarm-deploy-cicd
+ - swarm-deploy-platform
# - generate-report - can't moved to JJB, a lot of parameters is not supported like Inject environment variables
# - mark-reports - can't moved to JJB, a lot of parameters is not supported like Inject environment variables
- cookied-cicd-queens-dvr-sl-heat
diff --git a/jobs/templates/swarm-deploy-cicd.yml b/jobs/templates/swarm-deploy-cicd.yml
new file mode 100644
index 0000000..65e77fe
--- /dev/null
+++ b/jobs/templates/swarm-deploy-cicd.yml
@@ -0,0 +1,67 @@
+- job-template:
+ project-type: pipeline
+ description: '{job-description}'
+ concurrent: true
+ disabled: false
+ name: swarm-deploy-cicd
+ parameters:
+ - string:
+ default: '${{LAB_CONFIG_NAME}}'
+ description: 'Required: Fuel-devops environment name'
+ name: ENV_NAME
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Example: refs/changes/89/411189/36
+ (for now - only one reference allowed)'
+ name: TCP_QA_REFS
+ trim: 'false'
+ - string:
+ default: 'core,cicd'
+ description: 'Stacks to install using cfg01 node'
+ name: STACK_INSTALL
+ trim: 'false'
+ - string:
+ default: 4800
+ description: ''
+ name: STACK_INSTALL_TIMEOUT
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Required: Name of the jenkins slave to create the environment
+ To be set by the parent deployment job.'
+ name: PARENT_NODE_NAME
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Required: Workspace on the jenkins slave to reuse for the job
+ To be set by the parent deployment job.'
+ name: PARENT_WORKSPACE
+ trim: 'false'
+ - bool:
+ default: false
+ description: 'Shutdown the fuel-devops environment at the end of the job'
+ name: SHUTDOWN_ENV_ON_TEARDOWN
+ trim: 'false'
+ - bool:
+ default: false
+ description: 'Use "dos.py snapshot" to snapshot stages of deploy if ENV_MANAGER is devops'
+ name: MAKE_SNAPSHOT_STAGES
+ - string:
+ default: ''
+ description: ''
+ name: BATCH_SIZE
+ trim: 'false'
+ - bool:
+ default: false
+ description: Whether to perform dist-upgrade on virtual nodes during deployment
+ name: DIST_UPGRADE_NODES
+ pipeline-scm:
+ lightweight-checkout: false
+ scm:
+ - git:
+ branches:
+ - FETCH_HEAD
+ refspec: ${{TCP_QA_REFS}}
+ url: https://gerrit.mcp.mirantis.com/mcp/tcp-qa.git
+ script-path: jobs/pipelines/swarm-deploy-cicd.groovy
diff --git a/jobs/templates/swarm-deploy-platform.yml b/jobs/templates/swarm-deploy-platform.yml
new file mode 100644
index 0000000..1405ac4
--- /dev/null
+++ b/jobs/templates/swarm-deploy-platform.yml
@@ -0,0 +1,68 @@
+- job-template:
+ project-type: pipeline
+ description: '{job-description}'
+ concurrent: true
+ disabled: false
+ name: swarm-deploy-platform
+ parameters:
+ - string:
+ default: '${{LAB_CONFIG_NAME}}'
+ description: 'Required: Fuel-devops environment name'
+ name: ENV_NAME
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Example: refs/changes/89/411189/36
+ (for now - only one reference allowed)'
+ name: TCP_QA_REFS
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Stacks to install using CICD cluster. If IS_DRIVETRAIN is set to False,
+ stacks will be installed using cfg-day01 Jenkins'
+ name: STACK_INSTALL
+ trim: 'false'
+ - string:
+ default: 7200
+ description: ''
+ name: STACK_INSTALL_TIMEOUT
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Required: Name of the jenkins slave to create the environment
+ To be set by the parent deployment job.'
+ name: PARENT_NODE_NAME
+ trim: 'false'
+ - string:
+ default: ''
+ description: 'Required: Workspace on the jenkins slave to reuse for the job
+ To be set by the parent deployment job.'
+ name: PARENT_WORKSPACE
+ trim: 'false'
+ - bool:
+ default: false
+ description: 'Shutdown the fuel-devops environment at the end of the job'
+ name: SHUTDOWN_ENV_ON_TEARDOWN
+ trim: 'false'
+ - bool:
+ default: false
+ description: 'Use "dos.py snapshot" to snapshot stages of deploy if ENV_MANAGER is devops'
+ name: MAKE_SNAPSHOT_STAGES
+ - string:
+ default: ''
+ description: ''
+ name: BATCH_SIZE
+ trim: 'false'
+ - bool:
+ default: false
+ description: Whether to perform dist-upgrade on virtual nodes during deployment
+ name: DIST_UPGRADE_NODES
+ pipeline-scm:
+ lightweight-checkout: false
+ scm:
+ - git:
+ branches:
+ - FETCH_HEAD
+ refspec: ${{TCP_QA_REFS}}
+ url: https://gerrit.mcp.mirantis.com/mcp/tcp-qa.git
+ script-path: jobs/pipelines/swarm-deploy-platform.groovy