-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #21 from ksoclabs/print-results-to-stdout
Print results to stdout by default
- Loading branch information
Showing
4 changed files
with
8 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,7 +28,7 @@ jobs: | |
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: KSOC Guard | ||
uses: ksoclabs/[email protected].9 | ||
uses: ksoclabs/[email protected].10 | ||
with: | ||
ksoc_account_id: <KSOC_ACCOUNT_ID> | ||
ksoc_access_key_id: ${{ secrets.KSOC_ACCESS_KEY_ID }} | ||
|
@@ -51,7 +51,7 @@ jobs: | |
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: KSOC Guard | ||
uses: ksoclabs/[email protected].9 | ||
uses: ksoclabs/[email protected].10 | ||
with: | ||
policy_dir: /policies | ||
``` | ||
|
@@ -87,7 +87,7 @@ jobs: | |
uses: actions/checkout@v3 | ||
- name: KSOC Guard | ||
id: ksoc-guard | ||
uses: ksoclabs/[email protected].9 | ||
uses: ksoclabs/[email protected].10 | ||
with: | ||
ksoc_account_id: <KSOC_ACCOUNT_ID> | ||
ksoc_access_key_id: ${{ secrets.KSOC_ACCESS_KEY_ID }} | ||
|
@@ -132,7 +132,7 @@ jobs: | |
uses: actions/checkout@v3 | ||
- name: KSOC Guard | ||
id: ksoc-guard | ||
uses: ksoclabs/[email protected].9 | ||
uses: ksoclabs/[email protected].10 | ||
with: | ||
fail_on_severity: low | ||
format: sarif | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
#!/bin/sh -l | ||
|
||
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | ||
if [ $FORMAT = "sarif" ]; then | ||
SARIF_OUTPUT_FILE_NAME="./report.sarif" | ||
/app/policy-executor policies execute > $SARIF_OUTPUT_FILE_NAME | ||
exit_code=$? | ||
echo "sarif=$SARIF_OUTPUT_FILE_NAME" >> $GITHUB_OUTPUT | ||
else | ||
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | ||
echo "results<<$EOF" >> $GITHUB_OUTPUT | ||
/app/policy-executor policies execute >> $GITHUB_OUTPUT | ||
exit_code=$? | ||
echo "$EOF" >> $GITHUB_OUTPUT | ||
grep -v "$EOF" $GITHUB_OUTPUT | ||
fi | ||
exit $exit_code |