Skip to content

Commit

Permalink
OBS-361: Remove tini from Docker containers.
Browse files Browse the repository at this point in the history
  • Loading branch information
smarnach committed Nov 22, 2024
1 parent 8858c25 commit 83753cc
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions bin/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ shift

case ${SERVICE} in
web) ## Run web service
/app/bin/run_web.sh "$@"
exec /app/bin/run_web.sh "$@"
;;
shell) ## Open a shell or run something else
if [ -z "$*" ]; then
bash
if [ $# -eq 0 ]; then
exec bash
else
"$@"
exec "$@"
fi
;;
*)
Expand Down
2 changes: 1 addition & 1 deletion bin/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,4 @@ if [ -f metrics_emitted.txt ]; then
fi

# Run tests
"${PYTEST}" $@
exec "${PYTEST}" "$@"
2 changes: 1 addition & 1 deletion bin/run_web.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ STATSD_HOST=${STATSD_HOST:-localhost}
STATSD_PORT=${STATSD_PORT:-8125}
HOSTNAME=${HOSTNAME:-$(hostname)}

${CMD_PREFIX} gunicorn \
exec ${CMD_PREFIX} gunicorn \
--workers="${GUNICORN_WORKERS}" \
--worker-class="${GUNICORN_WORKER_CLASS}" \
--max-requests="${GUNICORN_MAX_REQUESTS}" \
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ services:
ports:
- "${EXPOSE_SENTRY_PORT:-8090}:8090"
command: run --host 0.0.0.0 --port 8090
stop_signal: SIGINT

# https://github.com/fsouza/fake-gcs-server
# Fake GCP GCS server for local development and testing
Expand Down
5 changes: 2 additions & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ RUN apt-get update && \
apt-transport-https \
build-essential \
git \
gcc \
tini && \
gcc && \
apt-get autoremove -y && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
Expand All @@ -40,4 +39,4 @@ ENV PYTHONDONTWRITEBYTECODE 1
ENV PORT 8000
EXPOSE $PORT

ENTRYPOINT ["tini", "--", "/app/bin/entrypoint.sh"]
ENTRYPOINT ["/app/bin/entrypoint.sh"]

0 comments on commit 83753cc

Please sign in to comment.