Skip to content

armgit / posta

Public Imported from GitHub
0

Self-hosted email delivery platform that enables applications to send emails via HTTP APIs while handling SMTP delivery, templates, storage, security, and analytics. Fully self-hostable alternative to services like SendGrid or Mailgun.

chore(docker): move healthcheck from Dockerfile to Docker compose example

Jonas Kaninda68fffd1c31fe
diff --git a/compose.yml b/compose.yml
index 6eb8804..5e8c583 100644
--- a/compose.yml
+++ b/compose.yml
@@ -11,6 +11,12 @@ services:
POSTA_JWT_SECRET: "change-me-in-production"
POSTA_ADMIN_EMAIL: "[email protected]"
POSTA_ADMIN_PASSWORD: "admin1234"
+ healthcheck:
+ test: ["CMD", "wget", "-qO-", "http://localhost:9000/healthz"]
+ interval: 30s
+ timeout: 5s
+ start_period: 10s
+ retries: 3
depends_on:
posta-db:
condition: service_healthy
diff --git a/docker/Dockerfile b/docker/Dockerfile
index c9a6462..0937b73 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -1,5 +1,5 @@
# UI build stage
-FROM node:22-alpine AS ui-builder
+FROM node:25-alpine AS ui-builder
WORKDIR /app/web
COPY web/package.json web/package-lock.json ./
@@ -47,8 +47,6 @@ COPY --from=ui-builder /app/web/dist /app/web/dist
ENV POSTA_WEB_DIR=/app/web/dist
-HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
- CMD wget -qO- http://localhost:${POSTA_PORT:-9000}/healthz || exit 1
USER posta
EXPOSE 9000
diff --git a/examples/compose.yml b/examples/compose.yml
index 5c9d2c3..b4fbd7a 100644
--- a/examples/compose.yml
+++ b/examples/compose.yml
@@ -22,6 +22,12 @@ services:
POSTA_ADMIN_EMAIL: "[email protected]"
POSTA_ADMIN_PASSWORD: "admin1234"
POSTA_EMBEDDED_WORKER: "true"
+ healthcheck:
+ test: ["CMD", "wget", "-qO-", "http://localhost:9000/healthz"]
+ interval: 30s
+ timeout: 5s
+ start_period: 10s
+ retries: 3
depends_on:
posta-db:
condition: service_healthy
diff --git a/examples/docker-compose-full.yml b/examples/docker-compose-full.yml
index a44dc77..a69c911 100644
--- a/examples/docker-compose-full.yml
+++ b/examples/docker-compose-full.yml
@@ -28,6 +28,12 @@ services:
POSTA_JWT_SECRET: "change-me-in-production"
POSTA_ADMIN_EMAIL: "[email protected]"
POSTA_ADMIN_PASSWORD: "admin1234"
+ healthcheck:
+ test: ["CMD", "wget", "-qO-", "http://localhost:9000/healthz"]
+ interval: 30s
+ timeout: 5s
+ start_period: 10s
+ retries: 3
depends_on:
posta-db:
condition: service_healthy