X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=jjb%2Flf-ci-jobs.yaml;h=2ede3e7b4b01df747b4bf88e160a58b278e00d18;hb=e35f8aa01680e9a8e86f0a9fc3091a8007a8ed21;hp=da70ba3f710f0c07ff57b29fdbc5ac3b4c9ed7bc;hpb=50bb84fc6e18daa187d5047968dc130b215a02c0;p=releng%2Fglobal-jjb.git diff --git a/jjb/lf-ci-jobs.yaml b/jjb/lf-ci-jobs.yaml index da70ba3f..2ede3e7b 100644 --- a/jjb/lf-ci-jobs.yaml +++ b/jjb/lf-ci-jobs.yaml @@ -1239,6 +1239,9 @@ git-url: '$GIT_URL/$PROJECT' github-url: 'https://github.com' openstack-cloud: vex + openstack-image-cleanup: true + openstack-image-cleanup-age: 30 + openstack-image-protect: true stream: master submodule-timeout: 10 @@ -1280,10 +1283,22 @@ - timed: '{obj:cron}' builders: + - lf-infra-pre-build - inject: properties-content: OS_CLOUD={openstack-cloud} - - shell: !include-raw-escape: ../shell/openstack-install.sh - - shell: !include-raw-escape: ../shell/openstack-protect-in-use-images.sh + # Images + - conditional-step: + condition-kind: boolean-expression + condition-expression: '{openstack-image-protect}' + steps: + - shell: !include-raw-escape: ../shell/openstack-protect-in-use-images.sh + - conditional-step: + condition-kind: boolean-expression + condition-expression: '{openstack-image-cleanup}' + steps: + - inject: + properties-content: OS_IMAGE_CLEANUP_AGE={openstack-image-cleanup-age} + - shell: !include-raw-escape: ../shell/openstack-cleanup-old-images.sh publishers: - lf-infra-publish