🔧(config) add healthcheck to docker-compose
This makes docker-compose up --wait work.
This commit is contained in:
@@ -41,6 +41,9 @@ CMD ["gunicorn", "-c", "/usr/local/etc/gunicorn/satosa.py"]
|
||||
# ---- Development image ----
|
||||
FROM common AS development
|
||||
|
||||
# Install curl (for healthchecks)
|
||||
RUN apt-get update && apt-get install -qy curl
|
||||
|
||||
# Playwright browsers
|
||||
ENV PLAYWRIGHT_BROWSERS_PATH=/pw-browsers
|
||||
RUN pip install playwright
|
||||
|
||||
@@ -40,6 +40,13 @@ services:
|
||||
- ./docker/files/usr/local/etc/gunicorn/satosa.py:/usr/local/etc/gunicorn/satosa.py
|
||||
depends_on:
|
||||
- redis
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "--fail", "http://localhost:8000/ping"]
|
||||
interval: 60s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
start_period: 30s
|
||||
start_interval: 1s
|
||||
|
||||
oidc-test-client:
|
||||
build: docker/oidc-test-client
|
||||
|
||||
Reference in New Issue
Block a user