fix(ci): share isolated runner workspace safely
GeoIntel release gates / Compile, test, contracts and builds (push) Failing after 1m43s
GeoIntel release gates / Python and npm vulnerability policy (push) Successful in 1m31s
GeoIntel release gates / GIS image, SBOM and container scan (push) Failing after 1m1s
Managed validation / full (pull_request) Canceled after 0s
GeoIntel release gates / Compile, test, contracts and builds (pull_request) Canceled after 0s
GeoIntel release gates / Python and npm vulnerability policy (pull_request) Canceled after 0s
GeoIntel release gates / GIS image, SBOM and container scan (pull_request) Canceled after 0s
GeoIntel release gates / Compile, test, contracts and builds (push) Failing after 1m43s
GeoIntel release gates / Python and npm vulnerability policy (push) Successful in 1m31s
GeoIntel release gates / GIS image, SBOM and container scan (push) Failing after 1m1s
Managed validation / full (pull_request) Canceled after 0s
GeoIntel release gates / Compile, test, contracts and builds (pull_request) Canceled after 0s
GeoIntel release gates / Python and npm vulnerability policy (pull_request) Canceled after 0s
GeoIntel release gates / GIS image, SBOM and container scan (pull_request) Canceled after 0s
This commit is contained in:
@@ -15,10 +15,16 @@ esac
|
||||
|
||||
docker image inspect "$TARGET_IMAGE" >/dev/null
|
||||
mkdir -p "$ROOT/$(dirname "$OUTPUT")"
|
||||
WORKDIR="/workspace"
|
||||
WORKSPACE_ARGS=(-v "$ROOT:/workspace")
|
||||
if docker inspect "${HOSTNAME:-}" >/dev/null 2>&1; then
|
||||
WORKDIR="$ROOT"
|
||||
WORKSPACE_ARGS=(--volumes-from "$HOSTNAME")
|
||||
fi
|
||||
docker run --rm \
|
||||
-v /var/run/docker.sock:/var/run/docker.sock \
|
||||
-v "$ROOT:/workspace" \
|
||||
-w /workspace \
|
||||
"${WORKSPACE_ARGS[@]}" \
|
||||
-w "$WORKDIR" \
|
||||
"$SYFT_IMAGE" \
|
||||
"$TARGET_IMAGE" \
|
||||
-o "spdx-json=$OUTPUT"
|
||||
|
||||
Reference in New Issue
Block a user