-
Couldn't load subscription status.
- Fork 13
fix: update prefix regix validation #786
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
Conversation
| type = string | ||
| nullable = true | ||
| description = "The prefix to be added to all resources created by this solution. To skip using a prefix, set this value to null or an empty string. The prefix must begin with a lowercase letter and may contain only lowercase letters, digits, and hyphens '-'. It should not exceed 16 characters, must not end with a hyphen('-'), and can not contain consecutive hyphens ('--'). Example: prod-0405-ocp. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." | ||
| description = "The prefix to add to all resources that this solution creates (e.g `prod`, `test`, `dev`). To not use any prefix value, you can enter the string `__NULL__`. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." |
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.
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.
Infact this is the terraform variable description - the description that is displayed in the projects UI is directly in the catalog JSON. For terraform description you can say null
solutions/quickstart/variables.tf
Outdated
| variable "prefix" { | ||
| type = string | ||
| description = "The prefix to be added to all resources created by this solution. To skip using a prefix, set this value to null or an empty string. The prefix must begin with a lowercase letter and may contain only lowercase letters, digits, and hyphens '-'. It should not exceed 16 characters, must not end with a hyphen('-'), and cannot contain consecutive hyphens ('--'). Example: `prod-0205-ocpqs`. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." | ||
| description = "The prefix to add to all resources that this solution creates (e.g `prod`, `test`, `dev`). To not use any prefix value, you can enter the string `__NULL__`. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." |
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.
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.
@iamar7 Can you add some info into the PR description. What is this PR addressing? Was there a bug in current regex?
I've updated the description with the information related to the changes, the PR is addressing the comments which are given here. Yes, the current regex does not allow a single alphabet as a prefix which I am resolving in this PR. |
|
/run pipeline |
solutions/quickstart/variables.tf
Outdated
| variable "prefix" { | ||
| type = string | ||
| description = "The prefix to be added to all resources created by this solution. To skip using a prefix, set this value to null or an empty string. The prefix must begin with a lowercase letter and may contain only lowercase letters, digits, and hyphens '-'. It should not exceed 16 characters, must not end with a hyphen('-'), and cannot contain consecutive hyphens ('--'). Example: `prod-0205-ocpqs`. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." | ||
| description = "The prefix to add to all resources that this solution creates (e.g `prod`, `test`, `dev`). To not use any prefix value, you can set to `null`. [Learn more](https://terraform-ibm-modules.github.io/documentation/#/prefix.md)." |
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.
why did you remove the text that says: "To skip using a prefix, set this value to null or an empty string"? I don't know why this text is changing at all to be honest? Why would we not want to include the details of the regex pattern it needs to comply with?
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.
I've re-added the text "To skip using a prefix, set this value to null or an empty string". The details of the regex pattern will be shown in error message. Apart from removing the regex pattern details there's not much change in the description.
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.
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.
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.
|
/run pipeline |
|
🎉 This PR is included in version 3.57.1 🎉 The release is available on:
Your semantic-release bot 📦🚀 |






Description
This PR resolves the case when a user want to have a single alphabet as a prefix. It also updates the description of the prefix variable as mentioned here.
Release required?
x.x.X)x.X.x)X.x.x)Release notes content
Run the pipeline
If the CI pipeline doesn't run when you create the PR, the PR requires a user with GitHub collaborators access to run the pipeline.
Run the CI pipeline when the PR is ready for review and you expect tests to pass. Add a comment to the PR with the following text:
Checklist for reviewers
For mergers