File tree 5 files changed +41
-10
lines changed
5 files changed +41
-10
lines changed Original file line number Diff line number Diff line change @@ -21,15 +21,23 @@ jobs:
21
21
- name : Checkout
22
22
uses : actions/checkout@v4
23
23
24
- - name : Run Microsoft Security DevOps Analysis
25
- uses : microsoft/security-devops-action@preview
26
- id : msdo
27
- continue-on-error : true
24
+ - name : Run PSRule analysis
25
+
28
26
with :
29
- tools : templateanalyzer
27
+ modules : PSRule.Rules.Azure
28
+ baseline : Azure.Pillar.Security
29
+ inputPath : bicep/*.test.bicep
30
+ outputFormat : Sarif
31
+ outputPath : reports/ps-rule-results.sarif
32
+ summary : true
33
+ continue-on-error : true
34
+
35
+ env :
36
+ PSRULE_CONFIGURATION_AZURE_BICEP_FILE_EXPANSION : ' true'
37
+ PSRULE_CONFIGURATION_AZURE_BICEP_FILE_EXPANSION_TIMEOUT : ' 30'
30
38
31
- - name : Upload alerts to Security tab
39
+ - name : Upload results to security tab
32
40
uses : github/codeql-action/upload-sarif@v3
33
41
if : github.repository_owner == 'Azure-Samples'
34
42
with :
35
- sarif_file : ${{ steps.msdo.outputs.sarifFile }}
43
+ sarif_file : reports/ps-rule-results.sarif
Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ module sqlDb 'modules/sqldb.bicep' = {
50
50
name : 'sqldb'
51
51
params : {
52
52
sqlServerName : sqlServerName
53
- sqlDatabaeName : applicationName
53
+ sqlDatabaseName : applicationName
54
54
administratorLogin : sqlAdminLogin
55
55
administratorPassword : sqlAdminPassword
56
56
location : location
Original file line number Diff line number Diff line change
1
+ // This file is for doing static analysis and contains sensible defaults
2
+ // for the bicep analyser to minimise false-positives and provide the best results.
3
+
4
+ // This file is not intended to be used as a runtime configuration file.
5
+
6
+ targetScope = 'resourceGroup'
7
+
8
+ // Random, dummy data for static analysis
9
+ param sqlAdminLogin string = newGuid ()
10
+ @secure ()
11
+ param sqlAdminPassword string = newGuid ()
12
+
13
+ module main 'main.bicep' = {
14
+ name : 'main'
15
+ params : {
16
+ staticWebAppLocation : 'westus2'
17
+ sqlAdminLogin : sqlAdminLogin
18
+ sqlAdminPassword : sqlAdminPassword
19
+ }
20
+ }
Original file line number Diff line number Diff line change 1
1
param sqlServerName string
2
- param sqlDatabaeName string
2
+ param sqlDatabaseName string
3
3
param location string
4
4
param administratorLogin string
5
5
@secure ()
@@ -20,7 +20,7 @@ resource sqlServer 'Microsoft.Sql/servers@2021-05-01-preview' = {
20
20
21
21
resource servers_rideshare_server_name_databases_Rideshare_name 'Microsoft.Sql/servers/databases@2021-05-01-preview' = {
22
22
parent : sqlServer
23
- name : sqlDatabaeName
23
+ name : sqlDatabaseName
24
24
location : location
25
25
tags : resourceTags
26
26
sku : {
Original file line number Diff line number Diff line change
1
+ # YAML: Set the AZURE_BICEP_FILE_EXPANSION configuration option to enable expansion
2
+ configuration :
3
+ AZURE_BICEP_FILE_EXPANSION : true
You can’t perform that action at this time.
0 commit comments