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

Setting nodeSelector and tolerations values with setValues or setValueTemplates #9692

Open
radnov opened this issue Jan 30, 2025 · 2 comments

Comments

@radnov
Copy link

radnov commented Jan 30, 2025

I'm trying to set nodeSelector and tolerations through the setValues and setValueTemplates configuration options, like this:

setValues:
  tolerations:
    - key: dedicated
      operator: Equal
      value: "true"
      effect: NoSchedule
  nodeSelector:
    dedicated: "true"

but when running skaffold deploy I get the following error:

Error: UPGRADE FAILED: failed to create resource: Deployment in version "v1" cannot be handled as a Deployment: json: cannot unmarshal bool into Go struct field PodSpec.spec.template.spec.nodeSelector of type string
deploying "web-client": install: exit status 1

I've also tried using setValueTemplates, but the result is the same.

Is it possible to configure a map based value like nodeSelector through setValues or setValueTemplates? It works fine if I use valuesFiles and a seaprate values file, but I'd like to avoid that.

@idsulik
Copy link
Contributor

idsulik commented Feb 1, 2025

value: true
value: "true"

remove the first value

@radnov
Copy link
Author

radnov commented Feb 3, 2025

value: true
value: "true"

remove the first value

That was a copy-paste mistake on my end. I've used the double-quoted value when trying to set those fields.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants