Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/expecho/policy-initiative-bicep-builder
Blazor app to aid in building a bicep template for azure policy initiatives
https://github.com/expecho/policy-initiative-bicep-builder
azure azure-governance azure-policies azure-policy blazor blazor-client blazor-webassembly
Last synced: 13 days ago
JSON representation
Blazor app to aid in building a bicep template for azure policy initiatives
- Host: GitHub
- URL: https://github.com/expecho/policy-initiative-bicep-builder
- Owner: Expecho
- License: mit
- Created: 2023-08-16T12:09:37.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-12-23T15:57:14.000Z (about 1 month ago)
- Last Synced: 2024-12-23T16:40:03.392Z (about 1 month ago)
- Topics: azure, azure-governance, azure-policies, azure-policy, blazor, blazor-client, blazor-webassembly
- Language: C#
- Homepage:
- Size: 1.02 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Policy Initiative Bicep Builder
This app allows you to visually select one or more policies and generates or updates a bicep file to deploy a policy initiative.
Accessible at https://policyinitiativebuilder.yellowbay-9c92f1d3.westeurope.azurecontainerapps.io/
![image](https://github.com/user-attachments/assets/4ed81f73-4b5d-445e-9127-ef6fe09a3de0)
![image](https://github.com/user-attachments/assets/e3d97066-d80a-40e6-aadd-147e9a306548)
## Tools & Resources
- [Radzen Blazor Components](https://blazor.radzen.com/docs/index.html)
- [Azure Policy Visual Studio Code Extension](https://marketplace.visualstudio.com/items?itemName=AzurePolicy.azurepolicyextension)## Resource Graph Explorer Queries
### Get a list of all exemptions
```sql
policyresources
| where type == "microsoft.authorization/policyexemptions"
| project
id,
name,
tenantId,
resourceGroup,
subscriptionId,
policyAssignmentId = properties.policyAssignmentId,
displayName = properties.displayName,
description = properties.description,
category = properties.exemptionCategory,
properties
```### Get a list of all policies
```sql
PolicyResources
| extend subscriptionId = tostring(properties.subscriptionId)
| join kind=leftouter (
ResourceContainers
| where type=='microsoft.resources/subscriptions'
| project subscriptionName=name, subscriptionId) on subscriptionId
| where type =~ 'Microsoft.PolicyInsights/PolicyStates'
| project
policyAssignmentName = properties.policyAssignmentName,
policy = properties.policyDefinitionReferenceId,
state = properties.complianceState,
effect = properties.policyDefinitionAction,
subscriptionId,
subscriptionName,
resourceGroup = properties.resourceGroup,
resourceType = properties.resourceType,
resourceId = properties.resourceId,
properties
| order by tostring(policyAssignmentName) desc, tostring(['state']) asc
```