-
Notifications
You must be signed in to change notification settings - Fork 175
procedures: Update backup registry auth secret documentation #3090
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,10 +7,7 @@ | |
| [id="devworkspace-backup-regular-oci-registry"] | ||
| = Configuring backup with a regular OCI-compatible registry | ||
|
|
||
| To use a regular OCI-compatible registry for backups, you need to provide registry credentials. Depending on your | ||
| RBAC policy, the token can be provided via a secret in the Operator {namespace} or in each {devworkspace} {namespace}. | ||
| Having the secret in the {devworkspace} {namespace} allows for using different registry accounts per {namespace} with more | ||
| granular access control. | ||
| To use a regular OCI-compatible registry for backups, you need to provide registry credentials. You can configure the {devworkspace} operator to automatically copy a registry authentication secret from the operator {namespace} to {devworkspace} {namespaces}, or you can manually create secrets in each {devworkspace} {namespace}. Having separate secrets in each {devworkspace} {namespace} allows for using different registry accounts per {namespace} with more granular access control. | ||
|
|
||
| [source,yaml,subs="+attributes,+quotes"] | ||
| ---- | ||
|
|
@@ -25,34 +22,58 @@ config: | |
| workspace: | ||
| backupCronJob: | ||
| enable: true | ||
| copyOperatorAuthSecret: true <2> | ||
| registry: | ||
| authSecret: devworkspace-backup-registry-auth | ||
| authSecret: my-registry-auth <3> | ||
| path: quay.io/my-company-org | ||
| schedule: '0 */4 * * *' | ||
| imagePullPolicy: Always | ||
| ---- | ||
| <1> For Red Hat OpenShift, the default installation namespace for the {devworkspace} operator is `openshift-operators`. See the xref:devworkspace-operator.adoc[{devworkspace} operator overview]. | ||
| <2> Set to `true` to enable automatic copying of the registry authentication secret from the operator {namespace} to {devworkspace} {namespaces}. The default value is `false`. | ||
| <3> The name of the secret in the operator {namespace} that contains registry credentials. This secret will be copied to {devworkspace} {namespaces} with the canonical name `devworkspace-backup-registry-auth`. | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [REQUIRED] Callouts <2> and <3> use future tense. Use present tense per IBM Style Guide. Suggested fix — replace: <2> Set to `true` to enable automatic copying of the registry authentication secret from the operator {namespace} to {devworkspace} {namespaces}. The default value is `false`.
<3> The name of the secret in the operator {namespace} that contains registry credentials. This secret will be copied to {devworkspace} {namespaces} with the canonical name `devworkspace-backup-registry-auth`.With: <2> When set to `true`, the operator copies the registry authentication secret from the operator {namespace} to each {devworkspace} {namespace}. The default is `false`.
<3> The name of the secret in the operator {namespace} that contains registry credentials. The operator copies this secret to each {devworkspace} {namespace} with the canonical name `devworkspace-backup-registry-auth`.(IBM Style Guide: use present tense for describing product behavior.) 🤖 RHAI docs Claude review
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Suggested fix for callouts <2> and <3>: Replace the current callouts: <2> Set to `true` to enable automatic copying of the registry authentication secret from the operator {namespace} to {devworkspace} {namespaces}. The default value is `false`.
<3> The name of the secret in the operator {namespace} that contains registry credentials. This secret will be copied to {devworkspace} {namespaces} with the canonical name `devworkspace-backup-registry-auth`.With: <2> When set to `true`, the operator copies the registry authentication secret from the operator {namespace} to each {devworkspace} {namespace}. The default is `false`.
<3> The name of the secret in the operator {namespace} that contains registry credentials. The operator copies this secret to each {devworkspace} {namespace} with the canonical name `devworkspace-backup-registry-auth`.🤖 RHAI docs Claude review |
||
| The `authSecret` must be named `devworkspace-backup-registry-auth`. It must reference a {kubernetes} Secret of type `kubernetes.io/dockerconfigjson` that contains credentials to access the registry. | ||
| The secret should be created in the installation {namespace} for the {devworkspace} operator. | ||
| == Configuring automatic secret copying | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [REQUIRED] Custom Suggested fix — restructure both approaches as alternatives within the . Configure how the operator provides registry credentials to {devworkspace} {namespaces}:
+
* *Option A: Automatic secret copying* — Set `copyOperatorAuthSecret: true` in the {devworkspace} operator configuration. The operator copies the registry authentication secret from the operator {namespace} to each {devworkspace} {namespace}.
+
Create the secret in the operator {namespace}:
+
...existing code blocks...
+
* *Option B: Manual secret creation* — Leave `copyOperatorAuthSecret` at the default (`false`) and manually create a secret named `devworkspace-backup-registry-auth` in each {devworkspace} {namespace}.
+
...existing code blocks...(Modular docs: procedure modules — no custom subheadings, only allowed sections.) 🤖 RHAI docs Claude review |
||
| To create one, you can use the following command: | ||
| When `copyOperatorAuthSecret` is set to `true`, the operator automatically copies the registry authentication secret from the operator {namespace} to each {devworkspace} {namespace}. | ||
|
|
||
| The `authSecret` field specifies the name of the secret in the operator {namespace}. This secret must be of type `kubernetes.io/dockerconfigjson` and contain credentials to access the registry. | ||
|
|
||
| To create the secret in the operator {namespace}, use the following command: | ||
|
|
||
| [source,shell,subs="+attributes,+quotes"] | ||
| ---- | ||
| {orch-cli} create secret docker-registry devworkspace-backup-registry-auth --from-file=config.json | ||
| {orch-cli} create secret docker-registry my-registry-auth \ | ||
| --namespace $OPERATOR_INSTALL_NAMESPACE \ | ||
| --from-file=config.json | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [REQUIRED] This issue also occurs on line ~57 in the Suggested fix: (Red Hat SSG Formatting: user-replaced values use 🤖 RHAI docs Claude review |
||
| ---- | ||
|
|
||
| The secret must contain a label `controller.devfile.io/watch-secret=true` to be recognized by the {devworkspace} Operator. | ||
| The secret must contain a label `controller.devfile.io/watch-secret=true` to be recognized by the {devworkspace} Operator: | ||
|
|
||
| [source,shell,subs="+attributes,+quotes"] | ||
| ---- | ||
| kubectl label secret devworkspace-backup-registry-auth controller.devfile.io/watch-secret=true | ||
| {orch-cli} label secret my-registry-auth \ | ||
| --namespace $OPERATOR_INSTALL_NAMESPACE \ | ||
| controller.devfile.io/watch-secret=true | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [REQUIRED] Suggested fix — replace: With: (Red Hat SSG Formatting: user-replaced values use 🤖 RHAI docs Claude review |
||
| ---- | ||
|
|
||
| [WARNING] | ||
| ==== | ||
| The {devworkspace} Operator copies the `devworkspace-backup-registry-auth` secret to each {devworkspace} {namespace} so that backups from user workspaces can be pushed to the registry. If you do not want that secret copied automatically, create a `devworkspace-backup-registry-auth` secret with user-specific credentials in each {devworkspace} {namespace} instead. | ||
| ==== | ||
| The operator will copy this secret to each {devworkspace} {namespace} with the canonical name `devworkspace-backup-registry-auth`. | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Future tense "will copy" — use present tense per IBM Style Guide. Suggested fix — replace:
With:
(IBM Style Guide: use present tense for describing product behavior.) 🤖 RHAI docs Claude review |
||
| == Manually creating secrets in workspace namespaces | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [REQUIRED] Custom Suggested fix — remove this (Modular docs: procedure modules — no custom subheadings, only allowed sections.) 🤖 RHAI docs Claude review |
||
| If `copyOperatorAuthSecret` is set to `false` (the default), the operator will not automatically copy secrets. Instead, you must manually create a secret named `devworkspace-backup-registry-auth` in each {devworkspace} {namespace}. | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Future tense "will not" — use present tense per IBM Style Guide. Suggested fix — replace:
With:
(IBM Style Guide: use present tense for describing product behavior.) 🤖 RHAI docs Claude review |
||
| To create the secret in a {devworkspace} {namespace}, use the following command: | ||
|
|
||
| [source,shell,subs="+attributes,+quotes"] | ||
| ---- | ||
| {orch-cli} create secret docker-registry devworkspace-backup-registry-auth \ | ||
| --namespace <workspace-namespace> \ | ||
| --from-file=config.json | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested fix — replace: With: (Red Hat SSG Formatting: user-replaced values use 🤖 RHAI docs Claude review |
||
| ---- | ||
|
|
||
| This approach allows you to use different registry credentials for different {devworkspace} {namespaces}. | ||
|
|
||
| IMPORTANT: If a secret named `devworkspace-backup-registry-auth` already exists in a {devworkspace} {namespace}, the operator will never overwrite it, even when `copyOperatorAuthSecret` is set to `true`. This ensures that user-provided secrets are always respected. | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Future tense "will never overwrite" — use present tense per IBM Style Guide. Suggested fix — replace:
With:
(IBM Style Guide: use present tense for describing product behavior.) 🤖 RHAI docs Claude review |
||
| include::partial$snip_defining-dwo-namespace-for-backups.adoc[] | ||
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.
[JTBD] Two issues with this intro paragraph:
Missing
[role="_abstract"]— every module must have a short description marked with[role="_abstract"]. Add it before this paragraph."you need to" → "you must" — IBM Style Guide: use "must" for requirements, not "need to".
Weak WHY — the abstract explains WHAT (provide credentials) but the core benefit (ensuring workspace data is backed up and recoverable) is absent. JTBD-aligned abstract should explain the user's job.
Suggested fix:
🤖 RHAI docs Claude review