services: tablejerseys-web: image: tablejerseys-web:latest container_name: tablejerseys-web # ports: # - "3001:3000" # Using 3001 to avoid conflict with other apps on port 3000 environment: - NODE_ENV=production # Add your environment variables here - NUXT_PUBLIC_FIREBASE_API_KEY=${NUXT_PUBLIC_FIREBASE_API_KEY} - NUXT_PUBLIC_FIREBASE_AUTH_DOMAIN=${NUXT_PUBLIC_FIREBASE_AUTH_DOMAIN} - NUXT_PUBLIC_FIREBASE_PROJECT_ID=${NUXT_PUBLIC_FIREBASE_PROJECT_ID} - NUXT_PUBLIC_FIREBASE_STORAGE_BUCKET=${NUXT_PUBLIC_FIREBASE_STORAGE_BUCKET} - NUXT_PUBLIC_FIREBASE_MESSAGING_SENDER_ID=${NUXT_PUBLIC_FIREBASE_MESSAGING_SENDER_ID} - NUXT_PUBLIC_FIREBASE_APP_ID=${NUXT_PUBLIC_FIREBASE_APP_ID} - NUXT_PUBLIC_STORAGE_URL=${NUXT_PUBLIC_STORAGE_URL} - NUXT_PUBLIC_BACKEND_URL=${NUXT_PUBLIC_BACKEND_URL} - NUXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=${NUXT_PUBLIC_STRIPE_PUBLISHABLE_KEY} - STRIPE_SECRET_KEY=${STRIPE_SECRET_KEY} restart: unless-stopped labels: - "traefik.enable=true" - "traefik.http.routers.tablejerseys-web.rule=Host(`${DOMAIN:-tablejerseys.com}`)" - "traefik.http.routers.tablejerseys-web.entrypoints=websecure" - "traefik.http.routers.tablejerseys-web.tls=true" - "traefik.http.routers.tablejerseys-web.tls.certresolver=le" - "traefik.http.services.tablejerseys-web.loadbalancer.server.port=3000" # HTTP to HTTPS redirect - "traefik.http.routers.tablejerseys-web-http.rule=Host(`${DOMAIN:-tablejerseys.com}`)" - "traefik.http.routers.tablejerseys-web-http.entrypoints=web" - "traefik.http.routers.tablejerseys-web-http.middlewares=https-redirect" - "traefik.http.middlewares.https-redirect.redirectscheme.scheme=https" networks: - traefik-public # Commented out - create this network first if using Traefik - crew-app-net # Commented out - create this network first if needed # - tablejerseys-network healthcheck: test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000/"] interval: 30s timeout: 10s retries: 3 start_period: 40s networks: traefik-public: external: true crew-app-net: external: true default: driver: bridge