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

What should happen when using "--dry-run=server" #12510

Closed
o4rz3l opened this issue Oct 19, 2023 · 3 comments
Closed

What should happen when using "--dry-run=server" #12510

o4rz3l opened this issue Oct 19, 2023 · 3 comments

Comments

@o4rz3l
Copy link

o4rz3l commented Oct 19, 2023

Output of helm version: 3.13.1

Output of kubectl version: v1.25.2

Hi, was trying the new dry-run=server feature but i'm not quite sure, what it does. In my point of view the difference between client und server should be:

  • --dry-run=client: try to render the template
  • --dry-run=server: try to render the template and do kubectl apply -f template.yaml --dry-run=server
    If the apply succeeds, status should be "green", if not, it should notify me, that an helm upgrade will fail.

I was trying it with a PVC resource. The default value for the size is 1GB. I manually increased the size to > 1GB. Now i ran helm upgrade --dry-run=server and from my point of view, it should fail - but it did not.
Running kubectl apply -f .. --dry-run=server returns exit code 1 due to the PVC size, which is the expected output since the PVC could not be downgraded in size,

So, what is --dry-run=server doing? Any hints to clearify this is appreciated!

Best Regards,
Oliver

@z4ce
Copy link
Contributor

z4ce commented Oct 20, 2023

--dry-run=server will enable lookup functions. This table pretty much sums it up.. we should probably add it to the docs somewhere:

#9426 (comment)

@gjenkins8
Copy link
Contributor

We thought about his a little when implementing --dry-run=server. The first/initial goal was to get lookup to work. The next step might be to get actual server-side validation enabled. But that would need further work/design. At the moment, agree with @z4ce that docs should explain this.

@o4rz3l
Copy link
Author

o4rz3l commented Oct 25, 2023

Ok, thanks for the clarification and agree, that should be in the docs ;)

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

No branches or pull requests

3 participants