Add Node.js/Express API service for booking backend
- New api/ service: Express + better-sqlite3, health check at GET /api/health, POST /api/bookings stores sessions with all required fields - Dockerfile with Alpine build deps for native sqlite3 module - docker-compose.yml: api service with volume mounts for data, signed-contracts, contracts - nginx.conf: proxy /api/ to api:3001; Immich regex locations remain higher priority - .gitignore: exclude SQLite db file and signed PDFs from version control Closes #1 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+12
@@ -86,6 +86,18 @@ http {
|
||||
proxy_ssl_server_name on;
|
||||
}
|
||||
|
||||
# Booking API — proxy to Node.js service
|
||||
# Immich regex locations above take priority for /api/immich-proxy and /api/fetch-immich/
|
||||
location /api/ {
|
||||
proxy_pass http://api:3001;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_read_timeout 30s;
|
||||
}
|
||||
|
||||
# Proxy endpoint for Immich share pages and API
|
||||
location ~ ^/api/fetch-immich/(.+)$ {
|
||||
resolver 8.8.8.8 1.1.1.1 valid=300s;
|
||||
|
||||
Reference in New Issue
Block a user