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

[hotfix] Fix Service account typo #285

Merged
merged 3 commits into from
Jun 3, 2022

Conversation

DmitriGekhtman
Copy link
Collaborator

@DmitriGekhtman DmitriGekhtman commented Jun 3, 2022

Why are these changes needed?

Fixes a typo in the operator's role that prevents it from managing service accounts, which in turn blocks setup of autoscaling Ray clusters.

TODO: How to test??

Related issue number

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • This PR is not tested :(

@DmitriGekhtman
Copy link
Collaborator Author

I'd propose banning the plural in English.
Definitely unnecessary.

@@ -54,7 +54,7 @@ rules:
- apiGroups:
- ""
resources:
- serviceaccount
- serviceaccounts
Copy link
Contributor

Choose a reason for hiding this comment

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

why do we need this change? serviceaccount should be correct.

Copy link
Contributor

Choose a reason for hiding this comment

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

If we need serviceaccount, we should update code

// +kubebuilder:rbac:groups=core,resources=serviceaccount,verbs=get;list;watch;create;delete

// +kubebuilder:rbac:groups=core,resources=serviceaccount,verbs=get;list;watch;create;delete

Change serviceaccount to serviceaccounts and make manifest to auto generate role.yaml

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It turns out the plural form is the correct way to specify the resource name (compare to "pods" and "services" elsewhere in this file).
With "serviceaccount" (singular) it fails to grant the necessary permissions (which are used only to set up the autoscaler's service account)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

If we need serviceaccount, we should update code

Thanks for pointing that out!! Will do.

@DmitriGekhtman
Copy link
Collaborator Author

One apple, ten apple.

Copy link
Contributor

@brucez-anyscale brucez-anyscale left a comment

Choose a reason for hiding this comment

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

Thanks for fixing this typo.

@DmitriGekhtman DmitriGekhtman merged commit e80e203 into ray-project:master Jun 3, 2022
@DmitriGekhtman DmitriGekhtman deleted the dmitri/fix-typo branch June 3, 2022 17:08
lowang-bh pushed a commit to lowang-bh/kuberay that referenced this pull request Sep 24, 2023
Fixes a typo in the operator's role that prevents it from managing service accounts, which in turn blocks setup of autoscaling Ray clusters.
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

Successfully merging this pull request may close these issues.

None yet

2 participants