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

Add prefix and suffix properties #422

Open
1 task done
manoelhc opened this issue Jun 27, 2023 · 3 comments
Open
1 task done

Add prefix and suffix properties #422

manoelhc opened this issue Jun 27, 2023 · 3 comments

Comments

@manoelhc
Copy link

manoelhc commented Jun 27, 2023

Terraform CLI and Provider Versions

Terraform 1.50.1
Random 3.0.0

Use Cases or Problem Statement

Whenever we have to generate things like a random username, starting with something like user-, we have to create something like a local variable to solve this suffix or prefix issue. If those properties are in place, we no longer need to care about these things, keeping the code cleaner and more readable.

Proposal

The proposal is simple: create both properties to add prefix and suffix strings to the generated string.

How much impact is this issue causing?

Low

Additional Information

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@bendbennett
Copy link
Contributor

Hi @manoelhc 👋

Thank you for submitting this issue. We will monitor the level of community interest in this proposal and will prioritise accordingly.

@manoelhc
Copy link
Author

Hi @manoelhc 👋

Thank you for submitting this issue. We will monitor the level of community interest in this proposal and will prioritise accordingly.

Thanks, @bendbennett.

@WaldoJeffers
Copy link

This would indeed be very nice. It feels a bit cumbersome to have a local variable containing only the suffix, and then doing string concatenation.

I think the randomId already has the prefix option

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants