-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Skaffold 1.28.1 doesn't override kubecontext via SKAFFOLD_KUBE_CONTEXT #6316
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
Comments
@artemkoru thanks for the detailed report here. I was able to reproduce the bug mentioned for v1.28.1 and you are correct this is a recent regression (v1.26.0 did work properly here). Additionally I wanted to clarify, the skaffold.yaml file in the repo should have NOTE: v1.26.0 - log snippets with
v1.28.1 - log snippets with
From the above logs for v1.28.1 you can see that both kubecontexts Still poking around to see what the exact issue is and what caused it. Between v1.26.0 and v1.28.1 these PRs seem like possible culprits: @gsquared94 any idea what the issue might be here? Just wanted to run this past you as I start poking around in case the change above might be related. |
@aaron-prindle You are right, I made a mistake. Fixed! Thanks for your comment. |
@aaron-prindle you're correct, #6024 is the culprit. Raised #6331 to fix this. |
Expected behavior
When I set the SKAFFOLD_KUBE_CONTEXT environment variable, I expect that the value
deploy.kubeContext
in skaffold.yaml to be ignored and skaffold will deploy my application to the kubecontext that is set in the SKAFFOLD_KUBE_CONTEXT variable. This works fine in versions <= 1.26.0.Actual behavior
Skaffold ignores SKAFFOLD_KUBE_CONTEXT environment variable and uses the value
deploy.kubeContext
from skaffold.yaml.Information
Skaffold version: 1.28.1, 1.27.0
Operating system: Darwin 20.5.0
Installed via:
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/v1.28.1/skaffold-darwin-amd64 &&
sudo install skaffold /usr/local/bin/
Contents of skaffold.yaml:
Steps to reproduce the behavior
export SKAFFOLD_KUBE_CONTEXT=kubecontext-2;skaffold deploy
Logs:
Thanks!
The text was updated successfully, but these errors were encountered: