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

better example for helm mountOptions #202

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

TiloGit
Copy link

@TiloGit TiloGit commented May 17, 2022

with current example --set nfs.mountOptions='nfsvers=3' I got error in helm:

Error: INSTALLATION FAILED: template: nfs-subdir-external-provisioner/templates/storageclass.yaml:28:19: executing "nfs-subdir-external-provisioner/templates/storageclass.yaml" at <.Values.nfs.mountOptions>: range can't iterate over nfsvers=3
helm.go:84: [debug] template: nfs-subdir-external-provisioner/templates/storageclass.yaml:28:19: executing "nfs-subdir-external-provisioner/templates/storageclass.yaml" at <.Values.nfs.mountOptions>: range can't iterate over nfsvers=3
INSTALLATION FAILED

this works better for me:
--set nfs.mountOptions={"nfsvers=3"}
or with other
--set nfs.mountOptions={"nolock\,nfsvers=3"}

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented May 17, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label May 17, 2022
@k8s-ci-robot
Copy link
Contributor

Welcome @TiloGit!

It looks like this is your first PR to kubernetes-sigs/nfs-subdir-external-provisioner 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/nfs-subdir-external-provisioner has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: TiloGit
To complete the pull request process, please assign yonatankahana after the PR has been reviewed.
You can assign the PR to them by writing /assign @yonatankahana in a comment when ready.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels May 17, 2022
Copy link
Contributor

@yonatankahana yonatankahana left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi @TiloGit,
mountOptions is an array.

using your solution (nfs.mountOptions={"nolock\,nfsvers=3"}) will produce:

mountOptions:
  - nolock,nfsvers=3

the correct way is to use nfs.mountOptions={"nolock"\,"nfsvers=3"} which will produce:

mountOptions:
  - nolock
  - nfsvers=3

@TiloGit
Copy link
Author

TiloGit commented May 26, 2022

@yonatankahana good call, I updated that.

@yonatankahana
Copy link
Contributor

@TiloGit can you please also bump the charts version (https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner/blob/master/charts/nfs-subdir-external-provisioner/Chart.yaml#L6) to 4.0.17?
any change to the helm chart require version release (unless, the helm release workflow will fail)

@@ -69,7 +69,7 @@ The following tables lists the configurable parameters of this chart and their d
| `leaderElection.enabled` | Enables or disables leader election | `true` |
| `nfs.server` | Hostname of the NFS server (required) | null (ip or hostname) |
| `nfs.path` | Basepath of the mount point to be used | `/nfs-storage` |
| `nfs.mountOptions` | Mount options (e.g. 'nfsvers=3') | null |
| `nfs.mountOptions` | Mount options (e.g. {"nolock"\,"nfsvers=3"}) | null |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good call. needed double slash to escape.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i am wondering, the slash required only in helm --set because helm reads the comma as a separator between variables and the slash escapes it. but in this context maybe {"nolock","nfsvers=3"} without escape character is more fit... what do you think?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TiloGit wdyt?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the install example list example with set. ; Can this be configured somehow else?
The values possible I would get from the Parameter list so if the set requires a escape the example should have it imho.

@TiloGit
Copy link
Author

TiloGit commented May 27, 2022

@TiloGit can you please also bump the charts version (https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner/blob/master/charts/nfs-subdir-external-provisioner/Chart.yaml#L6) to 4.0.17? any change to the helm chart require version release (unless, the helm release workflow will fail)

done, do you need this also for readme changes?

@yonatankahana
Copy link
Contributor

yonatankahana commented May 30, 2022

@TiloGit can you please also bump the charts version (https://github.com/kubernetes-sigs/nfs-subdir-external-provisioner/blob/master/charts/nfs-subdir-external-provisioner/Chart.yaml#L6) to 4.0.17? any change to the helm chart require version release (unless, the helm release workflow will fail)

done, do you need this also for readme changes?

yes, even though, personally, i don't consider it a version - the github action does detects it as a change and require version bump.
and it make some sense - the chart's README.md is part of the chart, its in the package, so... new version

better example for mountOptions readme

with current example  `--set nfs.mountOptions='nfsvers=3'` I got error in helm:

```console
Error: INSTALLATION FAILED: template: nfs-subdir-external-provisioner/templates/storageclass.yaml:28:19: executing "nfs-subdir-external-provisioner/templates/storageclass.yaml" at <.Values.nfs.mountOptions>: range can't iterate over nfsvers=3
helm.go:84: [debug] template: nfs-subdir-external-provisioner/templates/storageclass.yaml:28:19: executing "nfs-subdir-external-provisioner/templates/storageclass.yaml" at <.Values.nfs.mountOptions>: range can't iterate over nfsvers=3
INSTALLATION FAILED

bump helm version to 4.0.17 for readme change
@TiloGit
Copy link
Author

TiloGit commented May 30, 2022

@yonatankahana done, thanks for being patient with me.

@TiloGit
Copy link
Author

TiloGit commented Jun 14, 2022

@yonatankahana let me know if you need anything else from me.

@TiloGit
Copy link
Author

TiloGit commented Jul 15, 2022

@kmova and @wongma7 can you approve?

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 13, 2022
@TiloGit
Copy link
Author

TiloGit commented Oct 13, 2022

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 13, 2022
@yonatankahana
Copy link
Contributor

@TiloGit
i still think its wrong to escape the comma there.
the escape is true for command line but the examples are usually jsons and in this context there is no need to escape the comma.

@KyleSanderson
Copy link

This field doesn't exist... I'm editing the deployment in the nfs block and it's erroring out.

# * <nil>: Invalid value: "The edited file failed validation": ValidationError(Deployment.spec.template.spec.volumes[0].nfs): unknown field "mountOptions" in io.k8s.api.core.v1.NFSVolumeSource

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 4, 2023
@k8s-ci-robot
Copy link
Contributor

PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jun 2, 2023
@yonatankahana
Copy link
Contributor

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jun 2, 2023
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 19, 2024
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough active contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle rotten
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Feb 18, 2024
@KyleSanderson
Copy link

/remove-lifecycle rotten

@k8s-ci-robot k8s-ci-robot removed the lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. label Feb 19, 2024
@KyleSanderson
Copy link

/remove-lifecycle stale

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants