From e68043430bc11ba49b735b4fbd3df5ad14a719d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juha=20Yrj=C3=B6l=C3=A4?= Date: Sat, 19 Oct 2024 13:18:32 +0300 Subject: [PATCH] Add an app.json config for dokku to enable health checks --- .gitignore | 2 +- Dockerfile | 1 + docker/dokku-app.json | 11 +++++++++++ e2e-tests/.gitignore | 1 + 4 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 docker/dokku-app.json diff --git a/.gitignore b/.gitignore index fb2175f8c..d9dd2c52c 100644 --- a/.gitignore +++ b/.gitignore @@ -21,7 +21,7 @@ build-storybook.log /.env* /Attic/ /.envrc -/public/static/themes/ +/public/static/themes /.rgignore /test-results/ /playwright-report/ diff --git a/Dockerfile b/Dockerfile index ff4587877..b0883b24f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -99,6 +99,7 @@ COPY --from=builder --chown=nextjs:nodejs /app/public ./public COPY ./docker/start-server.sh /entrypoint.sh COPY ./docker/Caddyfile /etc/caddy/ +COPY ./docker/dokku-app.json ./app.json ARG BUILD_ID ARG SENTRY_RELEASE diff --git a/docker/dokku-app.json b/docker/dokku-app.json new file mode 100644 index 000000000..5ef122f2d --- /dev/null +++ b/docker/dokku-app.json @@ -0,0 +1,11 @@ +{ + "web": [ + { + "type": "startup", + "name": "web check", + "description": "Checking if the app responds to the /_health endpoint", + "path": "/_health", + "attempts": 3 + } + ] +} diff --git a/e2e-tests/.gitignore b/e2e-tests/.gitignore index edfde7b7a..b8ae02d83 100644 --- a/e2e-tests/.gitignore +++ b/e2e-tests/.gitignore @@ -1,2 +1,3 @@ /playwright-report/ /test-results/ +test-results.json