To do
Checklist
-
Tests (ref)
-
For each module that supports
Diagnostic Settings
Reference to AVM specs
NOTE: ⚠️ Make sure that if the module does not support e.g. metrics, that you update the logic accordingly
Role Assignments
Reference to AVM specs
Resource Locks
Reference to AVM specs
Tags
Reference to AVM specs
Managed Identities
Reference to AVM specs
NOTE: ⚠️ Make sure that if the module does not support e.g. user-assigned-identities, that you update the logic accordingly
Private Endpoints
Reference to AVM specs
Customer Managed Keys
Reference to AVM specs
NOTE: ⚠️ Make sure that if the module does not support e.g. metrics, that you update the logic accordingly
-
Other
Please use the following values explicitly as provided in the module index page:
For your module:
ModuleName - to name your module
TelemetryIdPrefix - to be used in your module's telemetry
NB Remove telemetry from child resources!
For your module's repository:
Repository name and folder path are defined in RepoURL
##Last steps before the tests:
uncomment the line of the CODEOWNERS file corresponding to your module folder
Issue template update
Ref https://azure.github.io/Azure-Verified-Modules/specs/bicep/#id-bcpnfr15---category-contributionsupport---avm-module-issue-template-file
As part of the “initial Pull Request” (that publishes the first version of the module), module owners MUST add an entry to the AVM Module Issue template file in the BRM repository (here).
###ReadMe
test your module
create the module's action in .github folder and remember to put the action either in your main branch and in the branch you created.
TEAMS
Create the GitHub teams defined in the ModuleOwnersGHTeam and ModuleContributorsGHTeam columns and grant them permissions as described here.
NB
On the interface, where you create the team, there's one field where you can provide the parent. Can you please choose avm-technical-reviewers-bicep for the owners team, and avm-module-contributors-bicep for the contributors team? Once you do this, it will come in as a request to Mate, and he can approve it.
No more need to ping Mate in chat for this!
Final steps
PR
- when you are ready for the PR in bicepRegistry repository, make sure you uncomment the line of the CODEOWNERS file corresponding to your module folder
- when you open the PR, put a link to AVM proposal issue, this will leave a comment on the proposal with a link to the PR
Reference repositories
Once the module is published on bicep registry,
- once the PR is merged, leave another comment on the proposal stating that it's done
then, Mate'll come in, do some final checks, apply labels, and update the index
- add the movedtoAVM file on carml repo and run set-module to add "this module will no be updated, it's moved, etc" on the readme file on CARML. Open the PR in CARML repo
Create the Github account and fork the bicep registry repo as described here https://azure.github.io/Azure-Verified-Modules/contributing/bicep/bicep-contribution-flow/
Choose the module you want to migrate in planned modules https://azure.github.io/Azure-Verified-Modules/indexes/bicep/bicep-resource-modules/#planned-modules
Check there is not already an issue for that module and open the issue here https://github.com/Azure/Azure-Verified-Modules/issues
Wait the confirmation email before start with the conversion
Update CARML alignment tracker: [Feature Request]: AVM alignment tracker #4020 in per-module edit checklist
Create a new branch in your fork and start with the following code updates
To do
Checklist
Tests (ref)
e2efolder (ref)minfolder todefaultscommonfolder tomaxwaf-alignedfolder (e.g., based oncommon). This test should not fail PSRule & show the module being deployed with best-practicesserviceShortparameter to align with the new naming (e.g.,wafforwaf-aligned). For now, we should continue usingminfordefaultsto align with PSRule.namePrefixinput parameter value from[[namePrefix]]to#_namePrefix_#(the reason being that Bicep has a compilation issue because of the prefix & suffix in another location)enableDefaultTelemetryparameter and reference in the test../../main.bicepmodule template reference to../../../main.bicepnamePrefix. For example:For each module that supports
Diagnostic Settings
diagnosticSettingTypedescribed in the above reference to a// Definitionsblock at the bottom of the template filediagnosticSettingsparameter as per the specs to the templateRole Assignments
roleAssignmentTypedescribed in the above reference to a// Definitionsblock at the bottom of the template fileroleAssignmentsparameter as per the specs (- should now reference the User-defined-type)builtInRoleNamesfrom thenested_roleAssignments.bicepfile and add them to the variables block of the main template. The new schema does not require the nested template. Also, reduce the list of specified roles to only those that make sense for this resource (ref)/ For, for example, Cognitive Services, we should only provide the important ones as Owner, Contributor, etc. + all service specific roles such as 'Cognitive Services User'.Resource Locks
lockTypedescribed in the above reference to a// Definitionsblock at the bottom of the template filelockparameter as per the specs (- should now reference the User-defined-type)Tags
tagsparameter as per the specsManaged Identities
managedIdentitiesTypedescribed in the above reference to a// Definitionsblock at the bottom of the template filemanagedIdentitiesparameter as per the specs to the templatePrivate Endpoints
privateEndpointTypedescribed in the above reference to a// Definitionsblock at the bottom of the template fileprivateEndpointsparameter as per the specs (- should now reference the User-defined-type)Customer Managed Keys
customerManagedKeyTypedescribed in the above reference to a// Definitionsblock at the bottom of the template filecustomerManagedKeyparameter as per the specs to the templateexistingresource references as per the specs-
- Note also that the new schema SHOULD support system-assigned-identities. As this cannot be done in a single deployment, you can find a reference how this would look like here
Other
version.jsonback to0.1in the main folder and remove version.json from child resourcesnullablefeature for parameters where-ever it makes sense to you (and ensure to test it). This enables us to simplify logic like in the following exampleCheck if outputs can be simplified as in the following example:
@description('The principal ID of the system assigned identity.')
OLD: output systemAssignedMIPrincipalId string = contains(workspace.identity, 'principalId') ? workspace.identity.principalId : ''
NEW: output systemAssignedMIPrincipalId string = workspace.?identity.?principalId ?? ''
if your module reference other AVM modules that are already in the bicep registry, be sure to point to the published one in your code (br/public:avm/res/......).
Please use the following values explicitly as provided in the module index page:
For your module:
ModuleName - to name your module
TelemetryIdPrefix - to be used in your module's telemetry
NB Remove telemetry from child resources!
For your module's repository:
Repository name and folder path are defined in RepoURL
##Last steps before the tests:
uncomment the line of the CODEOWNERS file corresponding to your module folder
Issue template update
Ref https://azure.github.io/Azure-Verified-Modules/specs/bicep/#id-bcpnfr15---category-contributionsupport---avm-module-issue-template-file
As part of the “initial Pull Request” (that publishes the first version of the module), module owners MUST add an entry to the AVM Module Issue template file in the BRM repository (here).
###ReadMe
main.bicepfileTo regenerate all needed files run the following commands:
test your module
create the module's action in .github folder and remember to put the action either in your main branch and in the branch you created.
TEAMS
Create the GitHub teams defined in the ModuleOwnersGHTeam and ModuleContributorsGHTeam columns and grant them permissions as described here.
NB
On the interface, where you create the team, there's one field where you can provide the parent. Can you please choose avm-technical-reviewers-bicep for the owners team, and avm-module-contributors-bicep for the contributors team? Once you do this, it will come in as a request to Mate, and he can approve it.
No more need to ping Mate in chat for this!
Final steps
PR
Reference repositories
Once the module is published on bicep registry,
then, Mate'll come in, do some final checks, apply labels, and update the index