Fix portfolio deploy container lookup
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
Keith Casko
2026-10-06 00:58:38 -04:00
parent 53a22c5ca6
commit 93764d1290
+1 -1
View File
@@ -11,7 +11,7 @@ steps:
commands:
- |
set -eu
CONTAINER_ID="$(docker ps --format '{{.ID}} {{.Ports}}' | awk '/:8091->80\/tcp/ {print $1; exit}')"
CONTAINER_ID="$(docker ps --filter publish=8091 --format '{{.ID}}' | head -n 1)"
test -n "$CONTAINER_ID" || { echo "No running portfolio container found on port 8091"; exit 1; }
HOST_SITE="$(docker inspect "$CONTAINER_ID" --format '{{range .Mounts}}{{if eq .Destination "/usr/share/nginx/html"}}{{.Source}}{{end}}{{end}}')"
test -n "$HOST_SITE" || { echo "Portfolio container has no /usr/share/nginx/html bind mount"; exit 1; }