X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=jjb%2Flf-ci-jobs.yaml;h=2ede3e7b4b01df747b4bf88e160a58b278e00d18;hb=e35f8aa01680e9a8e86f0a9fc3091a8007a8ed21;hp=733def52429ba301faf3c888c8d64e8a7e8bea18;hpb=3b9dcb2903e5cdc7740f59e44e4d6faf4e099b51;p=releng%2Fglobal-jjb.git diff --git a/jjb/lf-ci-jobs.yaml b/jjb/lf-ci-jobs.yaml index 733def52..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 @@ -1283,7 +1286,19 @@ - lf-infra-pre-build - inject: properties-content: OS_CLOUD={openstack-cloud} - - 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