Expose io.podman.compose.service label

Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
This commit is contained in:
Povilas Kanapickas 2025-05-29 21:59:46 +03:00
parent fc6bfc9931
commit 7b3276e5d7
2 changed files with 3 additions and 1 deletions

View File

@ -0,0 +1 @@
Added `io.podman.compose.service` label to created containers. It contains the same value as com.docker.compose.service.

View File

@ -2315,7 +2315,8 @@ class PodmanCompose:
labels.extend(podman_compose_labels)
labels.extend([
f"com.docker.compose.container-number={num}",
"com.docker.compose.service=" + service_name,
f"io.podman.compose.service={service_name}",
f"com.docker.compose.service={service_name}",
])
cnt["labels"] = labels
cnt["_service"] = service_name