Compare commits

...

3 Commits

Author SHA1 Message Date
2ad1231d83 Add healthcheck and update node version 2025-06-04 21:06:39 -04:00
9a712a096b Fix typo 2025-06-04 21:06:23 -04:00
c20536cd96 Fix database connection in docker 2025-06-04 20:27:13 -04:00
3 changed files with 10 additions and 6 deletions

View File

@ -1,12 +1,13 @@
TZ=UTC TZ=UTC
PORT=3333 PORT=3333
HOST=localhost HOST=0.0.0.0
LOG_LEVEL=info LOG_LEVEL=info
APP_KEY= APP_KEY=sMoYEqixvC3sgJO4WM9ej9ctlcVtAdCE
NODE_ENV=development NODE_ENV=development
SESSION_DRIVER=cookie SESSION_DRIVER=cookie
PG_USER=postgres
PG_PORT=5432 PG_PORT=5432
PG_HOST=localhost PG_HOST=db
PG_PASSWORD=password PG_PASSWORD=password
SENTRY_TOKEN= SENTRY_TOKEN=
SENTRY_ORG= SENTRY_ORG=

View File

@ -1,4 +1,6 @@
FROM node:22-alpine AS base FROM node:lts-alpine3.22 AS base
HEALTHCHECK --interval=5s --timeout=10s --start-period=5s --retries=5 \
CMD sh -c 'wget --no-verbose --tries=1 --spider http://127.0.0.1:3333 || exit 1'
# All deps stage # All deps stage
FROM base AS deps FROM base AS deps
@ -32,4 +34,5 @@ WORKDIR /app
COPY --from=production-deps /app/node_modules /app/node_modules COPY --from=production-deps /app/node_modules /app/node_modules
COPY --from=build /app/build /app COPY --from=build /app/build /app
EXPOSE 8080 EXPOSE 8080
CMD ["node", "./bin/server.js"] CMD ["node", "./bin/server.js"]

View File

@ -34,7 +34,7 @@ export default await Env.create(new URL('../', import.meta.url), {
PG_USER: Env.schema.string(), PG_USER: Env.schema.string(),
PG_PASSWORD: Env.schema.string(), PG_PASSWORD: Env.schema.string(),
WEBHOOK_URL: Env.schema.string(), WEBHOOK_URL: Env.schema.string.optional(),
QUERY_FILTER: Env.schema.string(), QUERY_FILTER: Env.schema.string(),
}) })