-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Cannot overwrite PATH environment variable properly #748
Comments
I've faced the same issue and while applying your workaround is sufficient when building your specific image, it doesn't help you when trying to offer a build pipeline for arbitrary images. |
Thanks, relates to #649. |
Currently, we only resolve environments which are set or passed via build-args. We can definitely add "$PATH" as a special case. |
#762 kind of resolve the issue, here is the output
|
so, i added tests on @prary branch and checked it out myself.
|
Actual behavior
Whenever I try to add anything to the PATH, the previous value is gone.
Expected behavior
Mimic the normal Docker behavior
To Reproduce
Try to build this Dockerfile:
When building it directly with Docker, the output is:
Whereas when using Kaniko, the output is:
One interesting thing, is that the default PATH is not the PATH from the base image that I'm extending, but instead a fixed one. This has already been reported in #650. Maybe #691 has some relation to this as well?
Kaniko image used: gcr.io/kaniko-project/executor:debug-v0.10.0 (although I have tried with many different ones)
For now, the workaround I've been using is to manually set the PATH to the one contained in the base image I'm extending :)
Thanks for the help :)
The text was updated successfully, but these errors were encountered: