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

Ability to multi-tag #217

Closed
LeDominik opened this issue Jun 25, 2018 · 12 comments
Closed

Ability to multi-tag #217

LeDominik opened this issue Jun 25, 2018 · 12 comments
Labels
kind/bug Something isn't working

Comments

@LeDominik
Copy link

In our build-pipeline we always add 2 tags: One for the git hash and one with the branch and or tag for releases, etc... So for docker build we simply pass two tags and then push both.

I'm wondering if there's a way to support this model in Kaniko as well...BTW awesome tool!

@priyawadhwa
Copy link
Collaborator

Hey @LeDominik, you can pass in multiple destinations to push the image too by setting the --destination flag multiple times.

@LeDominik
Copy link
Author

Oh cool, I didn't even try because for the build parameters it was clearly outlined in the help text 👍

@saschak094
Copy link

@priyawadhwa I've tried to use multiple --destination flags, but our new build image is only tagged and pushed once.

@priyawadhwa priyawadhwa reopened this Aug 28, 2018
@priyawadhwa priyawadhwa added the kind/bug Something isn't working label Aug 28, 2018
@priyawadhwa
Copy link
Collaborator

Hey @saschak094 I rebuilt the executor image and this should work now.

@saschak094
Copy link

Hey @priyawadhwa just tried it with the newest image but we are still not able to push to multiple destinations

@priyawadhwa
Copy link
Collaborator

Hey @saschak094 , thanks for letting me know! I just changed how we release the executor image, so hopefully shouldn't face this problem again. Could you try again with the new :latest image?

@ypadlyak
Copy link

Hey @priyawadhwa,
It does work for me. Thank you!

@d-sko
Copy link

d-sko commented Oct 21, 2019

Hello, I'm using kaniko in a GitLab CI Pipeline, which works fine with one tag, but with two destination flags I only get the tag of the last destination flag in the registry. Is something wrong with my command?:

/kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG --destination $CI_REGISTRY_IMAGE:latest

EDIT Sorry, it works, it was my fault: I've forgotten to tag the commits on my test-branch, so $CI_COMMIT_TAG was always empty.

@priyawadhwa
Copy link
Collaborator

Hey @d-sko what version of kaniko are you using?

@giulio1979
Copy link

Hi guys, I have same situation, on multiple destinations, only last one is reaching repository. We use gcr.io/kaniko-project/executor:debug image.

@callumd789
Copy link

@giulio1979 - did you anywhere when trying to set multiple destinations with the gcr.io/kaniko-project/executor:debug image?

@alinex
Copy link

alinex commented Nov 28, 2021

@callumd789 it is working for me, see https://gitlab.com/alinex/docker-mkdocs/blob/master/.gitlab-ci.yml

nils-van-zuijlen added a commit to nils-van-zuijlen/kaniko that referenced this issue Mar 4, 2024
The flag is mostly self-explanatory, but its usage for multiple push
was not documented anywhere.

Related to GoogleContainerTools#217, GoogleContainerTools#733
dchaley pushed a commit to dchaley/kaniko that referenced this issue Aug 2, 2024
The flag is mostly self-explanatory, but its usage for multiple push
was not documented anywhere.

Related to GoogleContainerTools#217, GoogleContainerTools#733

Co-authored-by: Nils Van Zuijlen <nils.van-zuijlen@mailo.com>
dchaley pushed a commit to dchaley/kaniko that referenced this issue Aug 2, 2024
The flag is mostly self-explanatory, but its usage for multiple push
was not documented anywhere.

Related to GoogleContainerTools#217, GoogleContainerTools#733

Co-authored-by Nils, submitted to the public domain.
Nils Van Zuijlen <nils.van-zuijlen@mailo.com>
See: GoogleContainerTools#3042
dchaley added a commit to dchaley/kaniko that referenced this issue Aug 2, 2024
The flag is mostly self-explanatory, but its usage for multiple push
was not documented anywhere.

Related to GoogleContainerTools#217, GoogleContainerTools#733

Co-authored-by Nils, submitted to the public domain.
Nils Van Zuijlen <nils.van-zuijlen@mailo.com>
See: GoogleContainerTools#3042
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

8 participants