Skip to content
This repository was archived by the owner on Apr 30, 2021. It is now read-only.

Commit 3e17196

Browse files
committed
Authenticate to DockerHub when building canary image
So we don't get caught in rate limiting issues when trying to pull a FROM image Based on this hack courtesy of Andy Paine: concourse/oci-build-task#14 (comment)
1 parent 3702b1f commit 3e17196

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

charts/gsp-cluster/templates/04-main-team-pipelines/cd-smoke-test-pipeline.yaml

+10-3
Original file line numberDiff line numberDiff line change
@@ -75,14 +75,21 @@ spec:
7575
repository: vito/oci-build-task
7676
username: ((dockerhubpull-concourse.username))
7777
password: ((dockerhubpull-concourse.password))
78-
params:
79-
CONTEXT: src/components/canary
8078
inputs:
8179
- name: src
8280
outputs:
8381
- name: image
8482
run:
85-
path: build
83+
path: ash
84+
args:
85+
- -c
86+
- |
87+
AUTH="$(echo -n '((dockerhubpull-concourse.username)):((dockerhubpull-concourse.password))' | base64)"
88+
mkdir docker_creds
89+
cat > docker_creds/config.json <<EOF
90+
{ "auths": { "https://index.docker.io/v1/": { "auth": "$AUTH" }}}
91+
EOF
92+
CONTEXT=src/components/canary DOCKER_CONFIG=docker_creds build
8693
- put: ecr
8794
params:
8895
image: image/image.tar

0 commit comments

Comments
 (0)