murano-deployment/murano-ci/jenkins/jobs/ci-infra.yaml

116 lines
4.1 KiB
YAML
Executable File

- job:
name: jobs-updater
node: master
project-type: freestyle
description: "<b>This job is managed by Jenkins Job Builder, do not edit it through WebUI.\
\n<p>Please use this repository to make changes: <a href=\"https://git.openstack.org/openstack/murano-deployment\">https://git.openstack.org/openstack/murano-deployment</a></b>\
\n<p><b>Title</b>: Jenkins Jobs Update job <br/>\
\n<b>Description</b>: This job updates all other jobs from murano-deployment repo. <br/>\
\n<b>Maintainer</b>: Alexey Deryugin<br/>"
defaults: global
disabled: false
concurrent: false
scm:
- git:
url: https://git.openstack.org/openstack/murano-deployment
branches:
- "master"
triggers:
- pollscm: "* * * * * "
builders:
- shell: "jenkins-jobs update murano-ci/jenkins/jobs"
- job:
name: gate-murano-deployment
project-type: freestyle
defaults: global
description: "<b>This job is managed by Jenkins Job Builder, do not edit it through WebUI.\
\n<p>Please use this repository to make changes: <a href=\"https://git.openstack.org/openstack/murano-deployment\">https://git.openstack.org/openstack/murano-deployment</a></b>\
\n<p>This job checks syntax in jenkins jobs, shell scripts"
disabled: false
concurrent: false
#In Jenkins v1.642.1 jobs triggered by zuul cannot be run on master
node: trusty-devstack-cz5608 || trusty-devstack-cz5680
builders:
- shell: |
#!/bin/bash
sudo pip install jenkins-job-builder
sudo apt-get install shellcheck
rm -rf murano-deployment
git clone https://git.openstack.org/openstack/murano-deployment
cd murano-deployment
git fetch $ZUUL_URL/openstack/murano-deployment $ZUUL_REF && git checkout FETCH_HEAD
bash ./murano-ci/scripts/syntax_check.sh
publishers:
- console-log
- job:
name: update-config
node: master
project-type: freestyle
description: "<b>This job is managed by Jenkins Job Builder, do not edit it through WebUI.\
\n<p>Please use this repository to make changes: <a href=\"https://git.openstack.org/openstack/murano-deployment\">https://git.openstack.org/openstack/murano-deployment</a></b>\
\n<p><b>Title</b>: Update job for Zuul and Nodepool <br/>\
\n<b>Description</b>: This job updates Zuul configs from murano-deployment repo. <br/>\
\n<b>Maintainer</b>: Alexey Deryugin<br/>"
defaults: global
disabled: false
concurrent: false
parameters:
- string:
name: MURANO_DEPLOYMENT_REF
scm:
- git:
url: https://git.openstack.org/openstack/murano-deployment
branches:
- "master"
triggers:
- pollscm: "* * * * * "
builders:
- shell: |
#!/bin/bash -ex
if [[ -n "$MURANO_DEPLOYMENT_REF" ]]; then
git fetch https://review.openstack.org/openstack/murano-deployment $MURANO_DEPLOYMENT_REF && git checkout FETCH_HEAD
fi
cp murano-ci/tools/update_config.sh /opt/ci-tools/
sudo -u zuul /opt/ci-tools/update_config.sh
sudo /etc/init.d/zuul reload
cp murano-ci/tools/update_pool.sh /opt/ci-tools/
- job:
name: update-pool
node: master
project-type: freestyle
description: "<b>This job is managed by Jenkins Job Builder, do not edit it through WebUI.\
\n<p>Please use this repository to make changes: <a href=\"https://git.openstack.org/openstack/murano-deployment\">https://git.openstack.org/openstack/murano-deployment</a></b>\
\n<p><b>Title</b>: Update Pool <br/>\
\n<b>Description</b>: This job updates vm pool using Nodepool. <br/>\
\n<b>Maintainer</b>: Alexey Deryugin<br/>"
defaults: global
disabled: false
concurrent: false
properties:
- build-blocker:
blocking-jobs:
- ".*"
triggers:
- timed: '0 6 * * *'
builders:
- shell: "/opt/bin/update_pool.sh"