-
Notifications
You must be signed in to change notification settings - Fork 140
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
Create naming conventions for resources #556
Comments
Created this to address some of the acceptance criteria in #549 |
Started this work at glenn/namingConventions |
@glennmusa I added these acceptance criteria from #503 and #549. I will close those backlog items.
|
Closed
4 tasks
Merged
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Benefit/Result/Outcome
So that deployed resources adopt generally accepted naming practices while providing a single place in source to modify the naming convention.
Description
We can use Bicep's string interpolation to create naming conventions and use Bicep's
replace()
function to do token replacement.For example, given a
resourcePrefix=foo
andresourceSuffix=bar
, here's how a naming convention could be defined, with reserved terms like<x>_token
used for token replacement.First, we define the naming convention:
missionlz/src/bicep/mlz.bicep
Line 17 in 1429d94
Then, we could do token replacement for resource type abbreviations. For example, here on L27 generating a resource group naming convention like
foo-rg-mlz_token-bar
:missionlz/src/bicep/mlz.bicep
Lines 19 to 31 in 1429d94
Finally, using another
replace()
call to replace the next token,mlz_token
. For example, here on L44 generating a hub resource group name like:foo-rg-hub-bar
:missionlz/src/bicep/mlz.bicep
Lines 42 to 97 in 1429d94
Acceptance Criteria
The text was updated successfully, but these errors were encountered: