diff --git a/gocd/sles.target.gocd.yaml b/gocd/sles.target.gocd.yaml index 746b53ab..de7386e4 100644 --- a/gocd/sles.target.gocd.yaml +++ b/gocd/sles.target.gocd.yaml @@ -78,3 +78,47 @@ pipelines: sleep 600 done osc -A https://api.suse.de/ api "/build/SUSE:SLFO:Products:SLES:16.0:PUBLISH/_result?view=summary&repository=images" | grep "result project" | grep 'code="published" state="published">' && echo PUBLISHED + + SLES16.0.Images.To.Publish: + group: SLES + materials: + repos: + git: git://botmaster.suse.de/suse-repos.git + auto_update: true + whitelist: + - SUSE:SLFO:Products:SLES:16.0_-_images.yaml + destination: repos + scripts: + auto_update: true + git: https://github.com/openSUSE/openSUSE-release-tools.git + whitelist: + - DO_NOT_TRIGGER + destination: scripts + environment_variables: + OSC_CONFIG: /home/go/config/oscrc-staging-bot + stages: + - Release.Images: + approval: manual + roles: + - SLE + environment_variables: + OSC_CONFIG: /home/go/config/oscrc-totest-manager + resources: + - staging-bot + tasks: + - script: |- + set -e + for product in kiwi-templates-Minimal 000productcompose agama-installer-SLES; do + osc -A https://api.suse.de release SUSE:SLFO:Products:SLES:16.0:TEST $product + done + sleep 600 + while (osc -A https://api.suse.de/ api "/build/SUSE:SLFO:Products:SLES:16.0:PUBLISH/_result?view=summary&repository=product" | grep "result project" | grep -v 'code="published" state="published">'); do + echo PENDING + sleep 600 + done + osc -A https://api.suse.de/ api "/build/SUSE:SLFO:Products:SLES:16.0:PUBLISH/_result?view=summary&repository=product" | grep "result project" | grep 'code="published" state="published">' && echo PUBLISHED + while (osc -A https://api.suse.de/ api "/build/SUSE:SLFO:Products:SLES:16.0:PUBLISH/_result?view=summary&repository=images" | grep "result project" | grep -v 'code="published" state="published">'); do + echo PENDING + sleep 600 + done + osc -A https://api.suse.de/ api "/build/SUSE:SLFO:Products:SLES:16.0:PUBLISH/_result?view=summary&repository=images" | grep "result project" | grep 'code="published" state="published">' && echo PUBLISHED