Skip to content

Commit 77d6862

Browse files
ENG-25676 add additional configuration options (#4)
1 parent 1ec2988 commit 77d6862

File tree

4 files changed

+50
-5
lines changed

4 files changed

+50
-5
lines changed

.github/workflows/pull_request_example.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,11 @@ jobs:
1616
api_key: ${{ secrets.ics_api_key }}
1717
base_url: ${{ secrets.ics_base_url }}
1818
config_name: AWS CIS Benchmark 1.4
19+
- name: Attach scan artifacts
20+
if: always()
21+
uses: actions/upload-artifact@v3
22+
with:
23+
name: mimics-scan-artifacts
24+
path: |
25+
./log/mimics*.log
26+
./ics_scan.*

.github/workflows/pull_request_with_advanced_security_center_example.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@ jobs:
1616
api_key: ${{ secrets.ics_api_key }}
1717
base_url: ${{ secrets.ics_base_url }}
1818
config_name: AWS CIS Benchmark 1.4
19+
- name: Attach scan artifacts
20+
if: always()
21+
uses: actions/upload-artifact@v3
22+
with:
23+
name: mimics-scan-artifacts
24+
path: |
25+
./log/mimics*.log
26+
./ics_scan.*
1927
- name: Upload SARIF file
2028
if: always()
2129
uses: github/codeql-action/upload-sarif@v2

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,15 @@ jobs:
4848
api_key: ${{ secrets.ics_api_key }}
4949
base_url: ${{ secrets.ics_base_url }}
5050
config_name: AWS CIS Benchmark 1.4
51+
# the following is optional but recommended to retrieve scan reports and logs
52+
- name: Attach scan artifacts
53+
if: always()
54+
uses: actions/upload-artifact@v3
55+
with:
56+
name: mimics-scan-artifacts
57+
path: |
58+
./log/mimics*.log
59+
./ics_scan.*
5160
# the following is optional but recommended to surface results to Github Advanced Security
5261
- name: Upload the sarif report to Github Advanced Security
5362
if: always()

action.yml

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,31 @@ author: Rapid7
33
description: >
44
Scans a cloudformation template and saves results to disk.
55
inputs:
6-
base_url:
7-
description: URL of ICS server
8-
required: true
96
api_key:
107
description: Api key for server at base_url
118
required: true
9+
base_url:
10+
description: URL of ICS server
11+
required: true
1212
config_name:
1313
description: Name of insightCloudSec configuration to run scan with
1414
required: true
15+
log_level:
16+
description: Sets log level ["trace", "debug", "info", "warn", "error", "fatal"] (default "info")
17+
required: false
18+
default: "info"
19+
log_path:
20+
description: Path to write log file
21+
required: false
22+
default: "./log/mimics.log"
23+
report_formats:
24+
description: Formats of scan result report artifacts (all,sarif,html,junitxml) (default "all")
25+
required: false
26+
default: "all"
27+
report_path:
28+
description: Path to write report files
29+
required: false
30+
default: "./"
1531
target:
1632
description: File(s) to scan
1733
required: false
@@ -30,7 +46,11 @@ runs:
3046
- ${{ inputs.target }}
3147
- -c
3248
- ${{ inputs.config_name }}
49+
- --log-level
50+
- ${{ inputs.log_level }}
3351
- --log-path
34-
- ./mimics.log
52+
- ${{ inputs.log_path }}
53+
- --report-path
54+
- ${{ inputs.report_path }}
3555
- --report-formats
36-
- all
56+
- ${{ inputs.report_formats }}

0 commit comments

Comments
 (0)