Skip to content

Commit a96fe1d

Browse files
committed
Add comments to Docker entrypoint explaining init container and sidecar modes
1 parent 93d7394 commit a96fe1d

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

agent/src/docker/entrypoint.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
#!/bin/sh
2+
# When /transfer exists (shared volume), copy the agent JAR there and exit.
3+
# This supports the Kubernetes init container pattern where this image provides
4+
# the agent JAR to the application container via a shared volume.
25
if [ -e /transfer ]; then
36
cp -r /agent/teamscale-jacoco-agent.jar /transfer
47
exit 0
58
fi
9+
# Otherwise, keep the container alive indefinitely as a sidecar.
610
trap : TERM INT
711
sleep infinity & wait

0 commit comments

Comments
 (0)