From 08e36a7d8a577bad56685492e43948b454b4bdc8 Mon Sep 17 00:00:00 2001 From: Boris Feld Date: Thu, 6 Jun 2019 18:06:16 +0200 Subject: [PATCH] Build tagged Docker images (#554) --- .taskcluster.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.taskcluster.yml b/.taskcluster.yml index 0d36b178..593674b7 100644 --- a/.taskcluster.yml +++ b/.taskcluster.yml @@ -138,13 +138,19 @@ tasks: privileged: true maxRunTime: 10800 image: mozilla/taskboot:0.1.3 + env: + REGISTRY: registry.hub.docker.com + VERSION: + $if: 'head_branch[:10] == "refs/tags/"' + then: {$eval: 'head_branch[10:]' } + else: "latest" command: - "/bin/sh" - "-lcxe" - "git clone ${repository} /code && cd /code && git checkout ${head_rev} && - taskboot --cache /cache --target /code build-compose --registry=registry.hub.docker.com --write /images --build-arg CHECK_MODELS=0" + taskboot --cache /cache --target /code build-compose --write /images --build-arg CHECK_MODELS=0 --tag $VERSION --tag latest" artifacts: public/bugbug: expires: {$fromNow: '2 weeks'}