compose/pkg/e2e/testdata/TestConfigFromEnv/compose.yaml
Nicolas De Loof cd1c0ca6ca test(e2e): configs, commit, export and logs scenarios
ImageExists and FileExists join the vocabulary, giving commit and
export a real observable: the legacy tests only asserted the commands
exited 0, the scenarios verify the committed image and the exported
archive actually exist. Both also drop their fixed image tags and
cwd-relative tar outputs for project-scoped tags and temp files, so
parallel runs cannot collide and nothing is left behind in the repo.

TestLocalComposeLogs waits for the echo service to exit before reading
logs (Eventually), closing the race the legacy test tolerated. The
follow and large-logs tests stay legacy: both drive a long-running
command in the background. ps_test.go stays legacy as well — it
verifies ps table/JSON formatting, which is inherently output-shaped.

Fixtures configs/, commit/ and export/ are removed.

Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2026-08-18 16:49:56 +02:00

33 lines
535 B
YAML

services:
from_env:
image: alpine
configs:
- source: from_env
command: cat /from_env
from_file:
image: alpine
configs:
- source: from_file
command: cat /from_file
inlined:
image: alpine
configs:
- source: inlined
command: cat /inlined
target:
image: alpine
configs:
- source: inlined
target: /target
command: cat /target
configs:
from_env:
environment: CONFIG
from_file:
file: config.txt
inlined:
content: This is my $CONFIG