-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (30 loc) · 1.15 KB
/
manual-deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
on: [workflow_dispatch]
name: DeployMainBicep
jobs:
deploy_main_bicep:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: azure/login@v1
with:
creds: ${{ secrets.AZURE_CREDENTIALS }}
- name: Get CarbonAware metrics
id: carbonaware-metrics
uses: webtonize/carbon-aware-sdk@dev
with:
location: westeurope,northeurope,swedencentral,uksouth,francecentral,germanywestcentral,norwayeast,francesouth,germanynorth,norwaywest,ukwest
- uses: azure/arm-deploy@v1
name: Run What-If bicep deployment
with:
subscriptionId: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
scope: subscription
region: ${{ steps.carboneaware-metrics.outputs.LowestEmissionsLocation }}
template: src/bicep/main.bicep
additionalArguments: "--what-if"
- uses: azure/arm-deploy@v1
name: Run Bicep deployment
with:
subscriptionId: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
scope: subscription
region: ${{ steps.carboneaware-metrics.outputs.LowestEmissionsLocation }}
template: src/bicep/main.bicep