Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use kaniko with docker config.json password #129

Merged
merged 6 commits into from
Oct 4, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions deploy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@
FROM scratch
ADD out/executor /kaniko/executor
ADD files/ca-certificates.crt /kaniko/ssl/certs/
ADD files/docker-credential-gcr /usr/local/bin/
ADD files/config.json /root/.docker/
RUN ["docker-credential-gcr", "config", "--token-source=env"]
ADD files/docker-credential-pass /usr/local/bin/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! We're actually only adding the gcr helper from a file here because it's still a special build we had to make to get it to run in this container. We're going to move it to a real release build soon. Would you mind using the ADD https:// format to add it without needing to check it in here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

turns out that docker-credential-pass is not needed at all for config.json credentials, so it's just a matter of documentation

ENV HOME /root
ENV PATH /usr/local/bin
ENV SSL_CERT_DIR=/kaniko/ssl/certs
Expand Down
Binary file added files/docker-credential-pass
Binary file not shown.