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

project_selector doc updates #13

Merged

Conversation

AdminTurnedDevOps
Copy link
Contributor

A few updates to the explanation of project_selector

@@ -45,7 +45,7 @@ Parameterize the helm install with `--set *` or `--values yourConfig.yaml` to co
| appSettings.pollingInterval | Interval to poll CloudTruth api for changes | integer | 300 | no |
| appSettings.debug | Debug logging and behavior | flag | false | no |
| projectMappings.root.environment | The CloudTruth environment to lookup parameter values for. | string | `default` | yes |
| projectMappings.root.project_selector | A regexp to limit the projects acted against (client-side). Supplies any named matches for template evaluation | string | "" | no |
| projectMappings.root.project_selector | A regexp, or static CloudTruth project name value, to limit the projects acted against (client-side). Supplies any named matches for template evaluation | string | "" | no |
Copy link
Member

Choose a reason for hiding this comment

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

Note this is always treated as a regexp, but a regexp can just be a simple string that matches the project name. However, if you don't anchor the regexp, then you may match more than the project you intended. e.g. foo matches the projects foobar and barfoo, but ^foo$ only matches foo.

@@ -143,6 +143,8 @@ standard ways, e.g. `kubectl edit projectmapping kubetruth-root`. The
`override` scope allows you to override the root scope's behavior for those
CloudTruth projects whose names match its `project_selector` pattern.

For the `project_selector`, which is defined under the *Usage* section, you can either use a regex (i.e - `"^k8s-"`) which matches any CloudTruth project that starts with `k8s-`, or a specific CloudTruth project name. For example, if you have a CloudTruth project called `kubernetes_secrets`, you'll want the `project_selector` value to be `"kubernetes_secrets"`.
Copy link
Member

Choose a reason for hiding this comment

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

See first comment about anchoring so that you don't inadvertently match not_kubernetes_secrets

@wr0ngway wr0ngway merged commit b644a1c into cloudtruth:main Mar 27, 2023
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.

2 participants