fix(deploy): use 'docker compose config --services' for reliable service name extraction
Replace fragile grep-based extraction that matched volume names (nats_data, tools_data) and 'null' as pseudo-services.
This commit is contained in:
@@ -164,7 +164,7 @@ jobs:
|
|||||||
TARGET_SERVICES=""
|
TARGET_SERVICES=""
|
||||||
for f in $TARGET_COMPOSE; do
|
for f in $TARGET_COMPOSE; do
|
||||||
if [ -f "$f" ]; then
|
if [ -f "$f" ]; then
|
||||||
svcs=$(grep -E '^\s{2}[a-zA-Z0-9_-]+:' "$f" | grep -v 'app-shared-net' | sed 's/://g' | xargs)
|
svcs=$($COMPOSE_CMD -f "$f" config --services 2>/dev/null | tr '\n' ' ' | xargs)
|
||||||
TARGET_SERVICES="$TARGET_SERVICES $svcs"
|
TARGET_SERVICES="$TARGET_SERVICES $svcs"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|||||||
Reference in New Issue
Block a user