Giter Club home page Giter Club logo

azure-naming-convention-initiative's Introduction

๐Ÿ‘ฎโ€โ™‚๏ธ Azure Naming Convention Initiative ๐Ÿšจ

This repository holds a bunch of bicep templates that creates and assigns Azure polices to audit or enforce a specific naming convention.

The preset follows Microsoft naming convention which was proposed here and adds some that where missing (e.g. private endpoints). For resource types where Microsoft doesn't make any suggestions I have created my own proposals, which can be found here.

However you can modify them according to your needs. The underyling module uses a notLike condition so you can check for pre- and postfixes, e.g. app-* would match app-some-web-application whereas *-app would match some-web-application-app.

๐Ÿ— Todo

  • Update templates, so that pattern takes an array of strings, instead of a single string

๐Ÿ‘‰ Important notes & limitations

  • After assigning an initiative/policy it can take up to 30min until it becomes active, so be patient!
  • You need to have the Resource Policy Contributor role assigned on the target subscription.
  • Bicep currenlty only supports a single scope why I decided to stick with subscription scope for the moment.
  • I didn't bundle them inside an initiative on purpose, so the user can freely decided on what to policy to use.
  • When deploying a policy assignment via template, we currently can't set a non-compliant message. This seems to be a limitation of ARM.

This polices are ready to use. You don't have to rebuild them. However, in case you would like to apply your own naming schema follow this steps

  1. Adjust the array at the begining of Generate-Biceps.ps1 according to your needs
  2. Run Generate-Biceps.ps1 that will outout *.biceps into the 'dist` folder
  3. Run Generate-Templates.ps1 to transpile them into JSON-based ARM templates (outputs to the dist folder)

๐Ÿš€ Currently implemented resources

๐ŸŸข Tested ๐ŸŸก Not tested yet, feedback welcome! ๐Ÿ”ด Not yet implemented, PR welcome!

General

Asset type Abbreviation Status Deploy
Management group mg- ๐ŸŸข Deploy to Azure
Resource group rg- ๐ŸŸข Deploy to Azure
Policy definition policy- ๐ŸŸก Deploy to Azure
API management service instance apim- ๐ŸŸก Deploy to Azure
Managed Identity id- ๐ŸŸข Deploy to Azure

Networking

Asset type Abbreviation Status Deploy
Private endpoint pe- ๐Ÿ”ด
Virtual network vnet- ๐ŸŸข Deploy to Azure
Subnet snet- ๐ŸŸก Deploy to Azure
Virtual network peering peer- ๐ŸŸก Deploy to Azure
Network interface (NIC) nic- ๐ŸŸก Deploy to Azure
Public IP address pip- ๐ŸŸก Deploy to Azure
Load balancer (internal) lbi- ๐Ÿ”ด
Load balancer (external) lbe- ๐Ÿ”ด
Network security group (NSG) nsg- ๐ŸŸก Deploy to Azure
Application security group (ASG) asg- ๐ŸŸก Deploy to Azure
Local network gateway lgw- ๐ŸŸก Deploy to Azure
Virtual network gateway vgw- ๐ŸŸก Deploy to Azure
VPN connection cn- ๐ŸŸก Deploy to Azure
ExpressRoute circuit erc- ๐ŸŸก Deploy to Azure
Application gateway agw- ๐ŸŸก Deploy to Azure
Route table route- ๐ŸŸก Deploy to Azure
User defined route (UDR) udr- ๐ŸŸก Deploy to Azure
Traffic Manager profile traf- ๐ŸŸก Deploy to Azure
Front door fd- ๐ŸŸก Deploy to Azure
CDN profile cdnp- ๐ŸŸข Deploy to Azure
CDN endpoint cdne- ๐ŸŸข Deploy to Azure
Web Application Firewall (WAF) policy waf ๐ŸŸก Deploy to Azure

Compute and Web

Asset type Abbreviation Status Deploy
Virtual machine vm ๐ŸŸข Deploy to Azure
Virtual machine scale set vmss- ๐ŸŸก Deploy to Azure
Availability set avail- ๐ŸŸก Deploy to Azure
Managed disk (OS) osdisk ๐Ÿ”ด
Managed disk (data) disk ๐Ÿ”ด
VM storage account stvm ๐Ÿ”ด
Azure Arc enabled server arcs- ๐Ÿ”ด
Azure Arc enabled Kubernetes cluster arck ๐Ÿ”ด
Container registry cr ๐Ÿ”ด
Container instance ci- ๐Ÿ”ด
AKS cluster aks- ๐ŸŸก Deploy to Azure
Service Fabric cluster sf- ๐Ÿ”ด
App Service environment ase- ๐Ÿ”ด
App Service plan plan- ๐ŸŸข Deploy to Azure
Web app app- ๐ŸŸข Deploy to Azure
Static web app stapp ๐Ÿ”ด
Function app func- ๐ŸŸก Deploy to Azure
Cloud service cld- ๐Ÿ”ด
Notification Hubs ntf- ๐ŸŸก Deploy to Azure
Notification Hubs namespace ntfns- ๐ŸŸก Deploy to Azure

Databases

Asset type Abbreviation Status Deploy
Azure SQL Database server sql- ๐ŸŸก Deploy to Azure
Azure SQL database sqldb- ๐ŸŸก Deploy to Azure
Azure Cosmos DB database cosmos- ๐ŸŸข Deploy to Azure
Azure Cache for Redis instance redis- ๐ŸŸข Deploy to Azure
MySQL database mysql- ๐ŸŸก Deploy to Azure
PostgreSQL database psql- ๐ŸŸข Deploy to Azure
Azure SQL Data Warehouse sqldw- ๐Ÿ”ด
Azure Synapse Analytics syn- ๐Ÿ”ด
SQL Server Stretch Database sqlstrdb- ๐Ÿ”ด
SQL Managed Instance sqlmi- ๐ŸŸก Deploy to Azure

Storage

Asset type Abbreviation Status Deploy
Storage account st ๐ŸŸข Deploy to Azure
Azure StorSimple ssimp ๐Ÿ”ด
Azure Container Registry acr ๐ŸŸข Deploy to Azure

AI and Machine Learning

Asset type Abbreviation Status Deploy
Azure Cognitive Search srch- ๐Ÿ”ด
Azure Cognitive Services cog- ๐Ÿ”ด
Azure Machine Learning workspace mlw- ๐Ÿ”ด

Analytics and IoT

Asset type Abbreviation Status Deploy
Azure Analysis Services server as ๐Ÿ”ด
Azure Databricks workspace dbw- ๐Ÿ”ด
Azure Stream Analytics asa- ๐Ÿ”ด
Azure Data Explorer cluster dec ๐Ÿ”ด
Azure Data Factory adf- ๐Ÿ”ด
Data Lake Store account dls ๐Ÿ”ด
Data Lake Analytics account dla ๐Ÿ”ด
HDInsight - Hadoop cluster hadoop- ๐Ÿ”ด
HDInsight - HBase cluster hbase- ๐Ÿ”ด
HDInsight - Kafka cluster kafka- ๐Ÿ”ด
HDInsight - Spark cluster spark- ๐Ÿ”ด
HDInsight - Storm cluster storm- ๐Ÿ”ด
HDInsight - ML Services cluster mls- ๐Ÿ”ด
IoT hub iot- ๐Ÿ”ด
Power BI Embedded pbi- ๐Ÿ”ด
Time Series Insights environment tsi- ๐Ÿ”ด

Developer tools

Asset type Abbreviation Status Deploy
App Configuration store appcs- ๐ŸŸข Deploy to Azure
Azure Static Web Apps stap- ๐ŸŸก Deploy to Azure

Integration

Asset type Abbreviation Status Deploy
Integration account ia- ๐ŸŸข Deploy to Azure
Logic apps logic- ๐ŸŸข Deploy to Azure
Service Bus sb- ๐ŸŸข Deploy to Azure
Service Bus queue sbq- ๐ŸŸข Deploy to Azure
Service Bus topic sbt- ๐ŸŸข Deploy to Azure
Event Hubs namespace evhns- ๐ŸŸข Deploy to Azure
Event hub evh- ๐ŸŸข Deploy to Azure
Event Grid domain evgd- ๐ŸŸข Deploy to Azure
Event Grid topic evgt- ๐ŸŸข Deploy to Azure
Event Grid system topic evgst- ๐Ÿ”ด
Event Grid Subscriptions evgs- ๐Ÿ”ด Microsoft.EventGrid/eventSubscriptions

Management and governance

Asset type Abbreviation Status Deploy
Automation account aa- ๐ŸŸก Deploy to Azure
Azure Monitor action group ag- ๐Ÿ”ด
Azure Purview instance pview- ๐Ÿ”ด
Blueprint bp- ๐Ÿ”ด
Blueprint assignment bpa- ๐Ÿ”ด
Key vault kv- ๐ŸŸข Deploy to Azure
Log Analytics workspace log- ๐ŸŸข Deploy to Azure
Application Insights appi- ๐ŸŸข Deploy to Azure

Migration

Asset type Abbreviation Status Deploy
Azure Migrate project migr- ๐Ÿ”ด
Database Migration Service instance dms- ๐ŸŸก Deploy to Azure
Recovery Services vault rsv- ๐ŸŸก Deploy to Azure

๐Ÿค“ Further reading

azure-naming-convention-initiative's People

Contributors

matthiasguentert avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.