File tree Expand file tree Collapse file tree 3 files changed +93
-0
lines changed Expand file tree Collapse file tree 3 files changed +93
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Manual Deploy
2
+
3
+ on :
4
+ workflow_dispatch :
5
+
6
+ jobs :
7
+ deploy :
8
+ runs-on : ubuntu-latest
9
+
10
+ steps :
11
+ - name : Checkout repository
12
+ uses : actions/checkout@v2
13
+
14
+ - name : Log in to Azure
15
+ uses : azure/login@v1
16
+ with :
17
+ creds : ${{ secrets.AZURE_CREDENTIALS }}
18
+ enable-AzPSSession : true
19
+
20
+ - name : Deploy ARM Template
21
+ uses : azure/arm-deploy@v1
22
+ with :
23
+ scope : resourceGroup
24
+ subscriptionId : ${{ secrets.AZURE_SUBSCRIPTION_ID }}
25
+ resourceGroupName : ${{ secrets.AZURE_RG }}
26
+ template : src/InfrastructureAsCode/main.bicep
27
+ # parameters: src/InfrastructureAsCode/main.parameters.json
28
+
29
+ - name : Deploy application
30
+ run : echo "Deploying application..."
Original file line number Diff line number Diff line change
1
+ {
2
+ "name" : " GitHubDevOpsCredential" ,
3
+ "issuer" : " https://token.actions.githubusercontent.com" ,
4
+ "subject" : " repo:bmoussaud/TechExcel-Accelerate-developer-productivity-with-GitHub-Copilot-and-Dev-Box" ,
5
+ "description" : " Deploy Azure resources from the TechExcel DevOps practices GitHub repo" ,
6
+ "audiences" : [
7
+ " api://AzureADTokenExchange"
8
+ ]
9
+ }
Original file line number Diff line number Diff line change @@ -15,3 +15,57 @@ var imageName = 'techexcel/dotnetcoreapp'
15
15
var startupCommand = ''
16
16
17
17
// TODO: complete this script
18
+ resource appServicePlan 'Microsoft.Web/serverfarms@2021-02-01' = {
19
+ name : appServicePlanName
20
+ location : location
21
+ sku : {
22
+ name : sku
23
+ tier : 'Standard'
24
+ }
25
+ properties : {
26
+ reserved : true
27
+ }
28
+ }
29
+
30
+ resource webApp 'Microsoft.Web/sites@2021-02-01' = {
31
+ name : webAppName
32
+ location : location
33
+ properties : {
34
+ serverFarmId : appServicePlan .id
35
+ siteConfig : {
36
+ linuxFxVersion : 'DOCKER|${imageName }'
37
+ appCommandLine : startupCommand
38
+ }
39
+ }
40
+ }
41
+
42
+ resource appInsights 'Microsoft.Insights/components@2020-02-02' = {
43
+ name : appInsightsName
44
+ location : location
45
+ kind : 'web'
46
+ properties : {
47
+ Application_Type : 'web'
48
+ }
49
+ }
50
+
51
+ resource logAnalytics 'Microsoft.OperationalInsights/workspaces@2021-06-01' = {
52
+ name : logAnalyticsName
53
+ location : location
54
+ properties : {
55
+ sku : {
56
+ name : 'PerGB2018'
57
+ }
58
+ retentionInDays : 30
59
+ }
60
+ }
61
+
62
+ resource containerRegistry 'Microsoft.ContainerRegistry/registries@2021-06-01-preview' = {
63
+ name : registryName
64
+ location : location
65
+ sku : {
66
+ name : registrySku
67
+ }
68
+ properties : {
69
+ adminUserEnabled : true
70
+ }
71
+ }
You can’t perform that action at this time.
0 commit comments