diff --git a/Dockerfile b/Dockerfile index 2a18258..2107194 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,8 +18,8 @@ FROM node:20-alpine WORKDIR /app -# Install PostgreSQL client for pg module -RUN apk add --no-cache postgresql-client +# Install PostgreSQL client and curl for healthcheck +RUN apk add --no-cache postgresql-client curl RUN addgroup -g 1001 -S nodejs && adduser -S nextjs -u 1001 @@ -47,6 +47,6 @@ USER nextjs EXPOSE 3000 -HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 CMD wget --no-verbose --tries=1 --spider http://localhost:3000/api/health || exit 1 +HEALTHCHECK --interval=30s --timeout=10s --start-period=40s --retries=3 CMD curl -f http://localhost:3000/api/health CMD ["/app/scripts/startup.sh"] diff --git a/openspec/changes/code-review-fix/tasks.md b/openspec/changes/code-review-fix/tasks.md index 9a30644..f709f12 100644 --- a/openspec/changes/code-review-fix/tasks.md +++ b/openspec/changes/code-review-fix/tasks.md @@ -59,7 +59,7 @@ - [x] 6.5 `[sonnet]` Add SHA256 checksum verification for TA-Lib download in `services/ml/Dockerfile` - [x] 6.6 `[haiku]` Remove `COPY --from=builder /app/node_modules ./node_modules` line from `Dockerfile:29` (standalone doesn't need it) - [x] 6.7 `[sonnet]` Pin Docker base images to `@sha256:` digests in both Dockerfiles -- [ ] 6.8 `[haiku]` Fix healthcheck tool mismatch: use same tool (curl) in Dockerfile and docker-compose.yml +- [x] 6.8 `[haiku]` Fix healthcheck tool mismatch: use same tool (curl) in Dockerfile and docker-compose.yml ## 7. Frontend — Stale Closures & Race Conditions