fix: ensure that cache-dir exists
CI / Test Merge SARIF Files (pull_request) Successful in 3s
CI / Test Get Images From Files (pull_request) Successful in 4s
CI / Test Setup DB (pull_request) Successful in 6s
CI / Test scan-config (pull_request) Failing after 12s
CI / Test scan-image (pull_request) Failing after 1m0s
CI / Test scan-fs (pull_request) Failing after 1m37s
CI / Test Merge SARIF Files (pull_request) Successful in 3s
CI / Test Get Images From Files (pull_request) Successful in 4s
CI / Test Setup DB (pull_request) Successful in 6s
CI / Test scan-config (pull_request) Failing after 12s
CI / Test scan-image (pull_request) Failing after 1m0s
CI / Test scan-fs (pull_request) Failing after 1m37s
This commit is contained in:
@@ -43,6 +43,7 @@ runs:
|
|||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
||||||
|
mkdir -p "$CACHE_DIR_IN"
|
||||||
scan_path=$(realpath "$SCAN_PATH_IN")
|
scan_path=$(realpath "$SCAN_PATH_IN")
|
||||||
cache_dir=$(realpath "$CACHE_DIR_IN")
|
cache_dir=$(realpath "$CACHE_DIR_IN")
|
||||||
mkdir -p "$OUTPUT_DIR_IN"
|
mkdir -p "$OUTPUT_DIR_IN"
|
||||||
|
|||||||
@@ -43,6 +43,7 @@ runs:
|
|||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
||||||
|
mkdir -p "$CACHE_DIR_IN"
|
||||||
scan_path=$(realpath "$SCAN_PATH_IN")
|
scan_path=$(realpath "$SCAN_PATH_IN")
|
||||||
cache_dir=$(realpath "$CACHE_DIR_IN")
|
cache_dir=$(realpath "$CACHE_DIR_IN")
|
||||||
mkdir -p "$OUTPUT_DIR_IN"
|
mkdir -p "$OUTPUT_DIR_IN"
|
||||||
|
|||||||
@@ -43,6 +43,7 @@ runs:
|
|||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
case "$OUTPUT_FILE" in */*|".."*) echo "FAIL: output-file must be a single file name (no path separators)"; exit 1 ;; esac
|
||||||
|
mkdir -p "$CACHE_DIR_IN"
|
||||||
cache_dir=$(realpath "$CACHE_DIR_IN")
|
cache_dir=$(realpath "$CACHE_DIR_IN")
|
||||||
mkdir -p "$OUTPUT_DIR_IN"
|
mkdir -p "$OUTPUT_DIR_IN"
|
||||||
output_dir=$(realpath "$OUTPUT_DIR_IN")
|
output_dir=$(realpath "$OUTPUT_DIR_IN")
|
||||||
|
|||||||
@@ -27,6 +27,9 @@ runs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
echo "current-date=$(date +%Y-%m-%d)" >> $GITHUB_OUTPUT
|
echo "current-date=$(date +%Y-%m-%d)" >> $GITHUB_OUTPUT
|
||||||
|
- name: Ensure Trivy cache directory exists
|
||||||
|
shell: bash
|
||||||
|
run: mkdir -p "${{ inputs.cache-dir }}"
|
||||||
- id: restore-db
|
- id: restore-db
|
||||||
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5
|
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5
|
||||||
with:
|
with:
|
||||||
|
|||||||
Reference in New Issue
Block a user