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

Added tolerations for cinder-csi-nodeplugin DaemonSet #8137

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions roles/kubernetes-apps/csi_driver/cinder/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ cinder_csi_controller_replicas: 1
# log on resize event. It is recommended to disable this option in this case.
# Defaults to false
# cinder_csi_rescan_on_resize: true

cinder_tolerations: []
Original file line number Diff line number Diff line change
Expand Up @@ -121,3 +121,7 @@ spec:
path: {{ kube_config_dir }}/cinder-cacert.pem
type: FileOrCreate
{% endif %}
{% if cinder_tolerations %}
tolerations:
{{ cinder_tolerations | to_nice_yaml(indent=2) | indent(width=8) }}
Copy link
Contributor

Choose a reason for hiding this comment

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

I hesitate to add empty tolerations into the spec.
For sample, ingress_nginx_tolerations is checked when adding it as

{% if ingress_nginx_tolerations %}
tolerations:
{{ ingress_nginx_tolerations | to_nice_yaml(indent=2) | indent(width=8) }}
{% endif %}

It is better to add the similar condition here like

{% if cinder_tolerations %}
      tolerations:
        {{ cinder_tolerations | to_nice_yaml(indent=2) | indent(width=8) }}
{% endif %}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the feedback.

I pushed this change as a separate commit - do you want me to squash the commits myself or will you squash them when you merge?

Copy link
Contributor

Choose a reason for hiding this comment

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

Thank you for updating the pull request.
It is better to squash multiple commits into a single by yourself before merging.
In addition, please rebase the pull request based on the latest master branch to solve molecule_tests issue.

Sorry for this inconvenience.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No problem. I squashed the commits and rebased on master, hope everything looks good now.

{% endif %}