Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix(helm/provisioner): prefer provisioner key if both psk and key are set#15417

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

Merged
johnstcn merged 5 commits intomainfromcj/provisioner-helm-key-psk-override
Nov 7, 2024

Conversation

johnstcn
Copy link
Member

@johnstcnjohnstcn commentedNov 6, 2024
edited
Loading

Relates to#15416

This PR modifies the provisioner helm chart logic when both PSK and key are set.
Previously, we would fail to install the chart.
Now we will setCODER_PROVISIONER_DAEMON_KEY if bothkeySecretName andpskSecretName are set.
Otherwise we will fall back to the existing behaviour of settingCODER_PROVISIONER_DAEMON_PSK.

This removes the requirement for a previous workaround of having to setpskSecretName to an empty string if usingkeySecretName /keySecretKey.

UPDATE: after consulting with@spikecurtis I have modified the above logic slightly.
We will now preferCODER_PROVISIONER_DAEMON_KEY only ifCODER_PROVISIONER_DAEMON_PSK is unchanged from its default value. Attempting to set both explicitly will still result in a failure to install the chart.

Additionally, a separate 'gotcha' exists aroundprovisionerDaemon.tags -- specifying bothCODER_PROVISIONER_DAEMON_KEY andCODER_PROVISIONERD_TAGS will result in the deployment failing to start. This is now detected upfront at helm install time.

@@ -111,7 +111,7 @@ spec:
valueFrom:
secretKeyRef:
key: psk
name: coder-provisionerd-psk
Copy link
MemberAuthor

@johnstcnjohnstcnNov 7, 2024
edited
Loading

Choose a reason for hiding this comment

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

review: renamed this to be clearer that it is not the default value

Comment on lines +61 to +64
{
name: "provisionerd_key_psk_empty_workaround",
expectedError: "",
},
Copy link
MemberAuthor

Choose a reason for hiding this comment

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

review: adding an explicit test for the old workaround

@johnstcnjohnstcn merged commit6781b0f intomainNov 7, 2024
26 checks passed
@johnstcnjohnstcn deleted the cj/provisioner-helm-key-psk-override branchNovember 7, 2024 12:34
bpmct pushed a commit that referenced this pull requestNov 8, 2024
… set (#15417)Relates to#15416This PR modifies the provisioner helm chart logic:- Previously, when both provisionerDaemon.keySecretName and provisionerDaemon.pskSecretName  were both set, we would fail to install the chart. This required users to have an obnoxious workaround  in place where setting provisionerDaemon.pskSecretName="" was required in order to use provisioner  keys. We now check for pskSecretName being set to the default value when keySecretName is also specified,  and switch to provisioner key authentication instead of PSK. The previous workaround is still supported.- We also had omitted to check for provisionerd.Tags being set along with provisionerDaemon.keySecretName.  This would result in a crashlooping provisioner deployment, as setting both of these configuration options is  not allowed. We now fast-fail the Helm deployment if we detect this scenario.(cherry picked from commit6781b0f)
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@spikecurtisspikecurtisspikecurtis approved these changes

@bpmctbpmctbpmct approved these changes

@EmyrkEmyrkAwaiting requested review from Emyrk

Assignees

@johnstcnjohnstcn

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@johnstcn@spikecurtis@bpmct

[8]ページ先頭

©2009-2025 Movatter.jp