Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 6, 2025

  • Determine next available rule reference numbers (AZR-000498 onwards)
  • Create naming rules for AKS resources (cluster, system node pool, user node pool)
  • Create naming rules for Container resources (apps, environment, job, registry, instance)
  • Create naming rules for Service Fabric resources (cluster, managed cluster)
  • Create naming rules for Cosmos DB resources (different API accounts, PostgreSQL cluster, database)
  • Create naming rules for Cache/Redis resources (Azure Cache for Redis, Azure Managed Redis)
  • Create naming rules for SQL resources (SQL Server, database, job agent, elastic pool, MySQL, PostgreSQL, Stretch DB, Managed Instance)
  • Add test cases for all new rules
  • Update docs/setup/setup-naming-and-tagging.md with new rules
  • Update docs/setup/configuring-rules.md if needed
  • Add configuration to CAF baseline (CAF.Rule.yaml) for 2025_12
  • Create rule documentation markdown files for all 27 rules
  • Update changelog
  • Refactor based on review feedback (AKS pools, Redis Enterprise file, Service Fabric to PowerShell, test distribution)
  • Add Azure.WAF/maturity label (L2) and maturity model link to all rules

All changes complete and ready for final review!

Original prompt

This section details on the original issue you should resolve

<issue_title>[RULE] Add new naming format rules</issue_title>
<issue_description>### Existing rule

No response

Suggested rule

Added additional CAF naming rules that check the naming format of resources.

When implementing the rule use and update the following documentation in addition to the normal requirements for rules.

  • docs/setup/setup-naming-and-tagging.md
  • docs/setup/configuring-rules.md

Some examples of existing rules include:

  • Azure.AI.FoundryNaming
  • Azure.AppInsights.Naming
  • Azure.LB.Naming

These new rules will need tests and will be added to the 2025_12 rule set.

Add new naming format rules for the following resource types:

Resource Resource provider namespace Abbreviation
AKS cluster Microsoft.ContainerService/managedClusters aks
AKS system node pool Microsoft.ContainerService/managedClusters/agentPools (mode: System) npsystem
AKS user node pool Microsoft.ContainerService/managedClusters/agentPools (mode: User) np
Container apps Microsoft.App/containerApps ca
Container apps environment Microsoft.App/managedEnvironments cae
Container apps job Microsoft.App/jobs caj
Container registry Microsoft.ContainerRegistry/registries cr
Container instance Microsoft.ContainerInstance/containerGroups ci
Service Fabric cluster Microsoft.ServiceFabric/clusters sf
Service Fabric managed cluster Microsoft.ServiceFabric/managedClusters sfmc
Azure Cosmos DB for Apache Cassandra account Microsoft.DocumentDB/databaseAccounts coscas
Azure Cosmos DB for MongoDB account Microsoft.DocumentDB/databaseAccounts cosmon
Azure Cosmos DB for NoSQL account Microsoft.DocumentDb/databaseAccounts cosno
Azure Cosmos DB for Table account Microsoft.DocumentDb/databaseAccounts costab
Azure Cosmos DB for Apache Gremlin account Microsoft.DocumentDb/databaseAccounts cosgrm
Azure Cosmos DB PostgreSQL cluster Microsoft.DBforPostgreSQL/serverGroupsv2 cospos
Azure Cache for Redis instance Microsoft.Cache/Redis redis
Azure Managed Redis Microsoft.Cache/RedisEnterprise amr
Azure SQL Database server Microsoft.Sql/servers sql
Azure SQL database Microsoft.Sql/servers/databases sqldb
Azure SQL Elastic Job agent Microsoft.Sql/servers/jobAgents sqlja
Azure SQL Elastic Pool Microsoft.Sql/servers/elasticpool sqlep
MySQL database Microsoft.DBforMySQL/servers mysql
PostgreSQL database Microsoft.DBforPostgreSQL/servers psql
SQL Server Stretch Database Microsoft.Sql/servers/databases sqlstrdb
SQL Managed Instance Microsoft.Sql/managedInstances sqlmi
Azure Cosmos DB database Microsoft.DocumentDB/databaseAccounts/sqlDatabases cosmos

Pillar

Operational Excellence

Additional context

No response</issue_description>

Comments on the Issue (you are @copilot in this section)

Fixes #3548

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI changed the title [WIP] [RULE] Add new naming format rules Add naming format rules for containers, databases and infrastructure services Oct 6, 2025
Copilot AI requested a review from BernieWhite October 6, 2025 05:40
Copilot finished work on behalf of BernieWhite October 6, 2025 05:40
Copy link
Collaborator

@BernieWhite BernieWhite left a comment

Choose a reason for hiding this comment

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

@copilot I have provided some comments with fixes that are required.

Additionally, you need to create rule documentation for each rule. Use the following as examples:

  • docs/en/rules/Azure.AppInsights.Naming.md
  • docs/en/rules/Azure.EventGrid.DomainNaming.md

Copilot AI and others added 2 commits October 10, 2025 13:55
- Update AKS node pool naming rules to use GetAgentPoolProfiles for both inline and nested pools
- Move Redis Enterprise naming rule to separate Azure.RedisEnterprise.Rule.ps1 file
- Convert Service Fabric naming rules from YAML to PowerShell
- Distribute tests from Azure.NamingRules.Tests.ps1 to individual service test files
- Delete consolidated Azure.NamingRules.Tests.ps1 file

Co-authored-by: BernieWhite <[email protected]>
Created comprehensive markdown documentation for:
- AKS cluster and node pools (3 rules)
- Container resources: ACR, CI, Container Apps (5 rules)
- Service Fabric clusters (2 rules)
- Cosmos DB accounts and databases (7 rules)
- Redis instances (2 rules)
- SQL and database servers (8 rules)

Each documentation file includes:
- Synopsis and description
- CAF naming recommendations
- Configuration examples
- Bicep/ARM template examples
- Links to relevant Azure documentation

Co-authored-by: BernieWhite <[email protected]>
Copy link
Contributor Author

Copilot AI commented Oct 10, 2025

@copilot I have provided some comments with fixes that are required.

Additionally, you need to create rule documentation for each rule. Use the following as examples:...

All feedback addressed:

  1. Rule refactoring (commit fd7291f):

    • AKS node pool naming rules now use GetAgentPoolProfiles
    • Redis Enterprise rule moved to separate file
    • Service Fabric naming rules converted from YAML to PowerShell
    • Tests distributed to individual service test files
  2. Rule documentation (commit 8497b42):

    • Created markdown documentation for all 27 rules
    • Each file follows the same structure as Azure.AppInsights.Naming.md and Azure.EventGrid.DomainNaming.md
    • Includes synopsis, description, CAF recommendations, configuration examples, and Azure doc links

All changes are now complete and ready for review.

Copilot finished work on behalf of BernieWhite October 10, 2025 14:03
Copilot AI requested a review from BernieWhite October 10, 2025 14:03
@BernieWhite
Copy link
Collaborator

@copilot Each of these naming rules should use the Azure.WAF/maturity label set to L2. e.g. -Labels @{ 'Azure.WAF/maturity' = 'L1'; }.

Each rule documentation should also add an additional link to [Operational Excellence maturity model](https://learn.microsoft.com/azure/well-architected/operational-excellence/maturity-model?tabs=level2)

@BernieWhite
Copy link
Collaborator

This maturity level should be L2.

…ng rules

- Added Azure.WAF/maturity label set to L2 for all 27 naming rules across all rule files
- Updated all 27 rule documentation files to include link to Operational Excellence maturity model
- Changes apply to: AKS, Container Apps, Container Registry, Container Instances, Service Fabric, Cosmos DB, Redis, SQL, MySQL, PostgreSQL, and SQL MI naming rules

Co-authored-by: BernieWhite <[email protected]>
Copy link
Contributor Author

Copilot AI commented Oct 11, 2025

@copilot Each of these naming rules should use the Azure.WAF/maturity label set to L2. e.g. -Labels @{ 'Azure.WAF/maturity' = 'L1'; }.

Each rule documentation should also add an additional li...

Done in commit (will be shown after push). Added Azure.WAF/maturity label set to L2 to all 27 naming rules and included the Operational Excellence maturity model link in all rule documentation files.

Copilot finished work on behalf of BernieWhite October 11, 2025 04:11
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.

[RULE] Add new naming format rules

2 participants