- Notifications
You must be signed in to change notification settings - Fork1.1k
feat: add --key flag to provisionerd start#14002
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
5d4cbc0 to47aa9c4Compare| ifprovisionerKey!="" { | ||
| logger.Info(ctx,"provisioner key auth automatically sets tag "+provisionersdk.TagScope+" empty") | ||
| // no scope tag will default to org scope | ||
| delete(tags,provisionersdk.TagScope) | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Is this because it's all done on coderd? And we should be passing no tags into the provisioner daemon?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Correct, the API will actually fail if you pass any tags + a provisioner key. I felt this was a good opportunity to break that behavior altogether.
| // If using PSK auth, the daemon is, by definition, scoped to the organization. | ||
| tags=provisionersdk.MutateTags(uuid.Nil,tags) | ||
| returntags,nil | ||
| iftags!=nil&&!maps.Equal(tags,map[string]string{}) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
TILmaps.Equal
Uh oh!
There was an error while loading.Please reload this page.
What this changes:
--keyflag tocoder provisionerd startfor providing a provisioner key to authenticate with.--tagor--pskwhen using--keyflag.