diff --git a/.gitignore b/.gitignore index 3b462cb..30e4cdd 100644 --- a/.gitignore +++ b/.gitignore @@ -17,6 +17,7 @@ Thumbs.db .env.* !.env.example !.env.test +pgdata # Vite vite.config.js.timestamp-* diff --git a/Dockerfile b/Dockerfile index 301f920..85d0ab8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -35,8 +35,15 @@ RUN pnpm install --frozen-lockfile --prod # Copy built application from builder COPY --from=builder /app/build ./build +# Install netcat for health checks +RUN apk add --no-cache netcat-openbsd + +# Copy entrypoint script +COPY entrypoint.sh /app/entrypoint.sh +RUN chmod +x /app/entrypoint.sh + # Expose port (SvelteKit Node adapter default) -EXPOSE 5173 +EXPOSE 3000 # Start the application -CMD ["node", "build"] +ENTRYPOINT ["/app/entrypoint.sh"] diff --git a/compose.yaml b/compose.yaml index 7bf5cfb..644be24 100644 --- a/compose.yaml +++ b/compose.yaml @@ -9,6 +9,7 @@ services: POSTGRES_PASSWORD: mysecretpassword POSTGRES_DB: memento volumes: + # - ~/tmp/pgdata:/var/lib/postgresql - ./pgdata:/var/lib/postgresql app: