Skip to content

Commit 7a82350

Browse files
committed
fix(docker): add tini to prevent zombie processes
1 parent aa07198 commit 7a82350

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ FROM python:3.13-slim
2323

2424
WORKDIR /app
2525

26-
RUN apt-get update && apt-get install -y --no-install-recommends sudo curl ca-certificates gosu && rm -rf /var/lib/apt/lists/* && \
26+
RUN apt-get update && apt-get install -y --no-install-recommends sudo curl ca-certificates gosu tini && rm -rf /var/lib/apt/lists/* && \
2727
groupadd -r appuser -g 1000 && \
2828
useradd -r -u 1000 -g appuser -m -s /bin/bash appuser && \
2929
echo "appuser ALL=(ALL) NOPASSWD: /usr/bin/apt-get" >> /etc/sudoers.d/appuser && \

entrypoint.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,5 @@ if grep -q "^local:" /app/config.yaml 2>/dev/null; then
1717
fi
1818
fi
1919

20-
exec gosu appuser "$@"
20+
# Use tini as PID 1 to clean up zombie processes (e.g. docker health checks)
21+
exec tini -- gosu appuser "$@"

0 commit comments

Comments
 (0)