Skip to content

Instantly share code, notes, and snippets.

@oismaelash
Created November 17, 2025 03:16
Show Gist options
  • Select an option

  • Save oismaelash/c53365538908f063f89a6981710a9a67 to your computer and use it in GitHub Desktop.

Select an option

Save oismaelash/c53365538908f063f89a6981710a9a67 to your computer and use it in GitHub Desktop.
services:
redis:
image: redis:7-alpine
restart: unless-stopped
networks:
- internal
backend:
image: ghcr.io/oismaelash/gomkt-backend:${APP_VERSION}
environment:
- PORT=3001
- NODE_ENV=production
- SUPABASE_URL=https://bokhhzpsbxcugsqgdhoj.supabase.co
- SUPABASE_SERVICE_ROLE_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImJva2hoenBzYnhjdWdzcWdkaG9qIiwicm9sZSI6InNlcnZpY2Vfcm9sZSIsImlhdCI6MTc2MzI5NzM2MSwiZXhwIjoyMDc4ODczMzYxfQ.AgBFQ-19IVjttunpXPj_BFQjk2xvpMzcAEOMNQgUCrA
- REDIS_HOST=redis
- REDIS_PORT=6379
- JWT_SECRET=dev-secret-key-change-in-production
- JWT_EXPIRES_IN=1d
- IPINFO_API_URL=https://ipinfo.io
- IP_API_URL=http://ip-api.com
- IPIFY_API_URL=https://api.ipify.org
- GOOGLE_CLIENT_ID=942214907495-j1lr6l5h17stto4bn7h6870sptj216hi.apps.googleusercontent.com
- GOOGLE_CLIENT_SECRET=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
- GOOGLE_REDIRECT_URI=https://api.${CUSTOM_DOMAIN:-${BASE_DOMAIN}}/api/auth/google/callback
- BACKEND_URL=https://api.${CUSTOM_DOMAIN:-${BASE_DOMAIN}}
- FRONTEND_URL=https://${CUSTOM_DOMAIN:-${BASE_DOMAIN}}
depends_on:
- redis
restart: unless-stopped
networks:
- traefik
- internal
healthcheck:
test: ["CMD-SHELL", "node -e \"require('http').get('http://localhost:3001/', (r) => {process.exit(r.statusCode === 200 ? 0 : 1)}).on('error', () => process.exit(1))\" || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
labels:
- traefik.enable=true
- traefik.docker.network=traefik
- traefik.http.routers.backend.rule=Host(`api.${BASE_DOMAIN}`)${CUSTOM_DOMAIN:+ || Host(`api.${CUSTOM_DOMAIN}`)}
- traefik.http.routers.backend.entrypoints=websecure
- traefik.http.routers.backend.tls=true
- traefik.http.routers.backend.tls.certresolver=letsencrypt
- traefik.http.services.backend.loadbalancer.server.port=3001
frontend:
image: ghcr.io/oismaelash/gomkt-frontend:${APP_VERSION}
environment:
- PORT=3000
- NODE_ENV=production
- NEXT_PUBLIC_API_URL=https://api.${CUSTOM_DOMAIN:-${BASE_DOMAIN}}/api
- NEXT_PUBLIC_API_BASE_URL=https://api.${CUSTOM_DOMAIN:-${BASE_DOMAIN}}
- NEXT_PUBLIC_ANALYTICS_SCRIPT_URL=https://analytics.microsaas.marketing/script.js
- NEXT_PUBLIC_ANALYTICS_WEBSITE_ID=f2f24091-6429-4828-b8c2-9545fa06ad42
- NEXT_PUBLIC_IMAGE_DOMAINS=${BASE_DOMAIN},${CUSTOM_DOMAIN}
depends_on:
- backend
restart: unless-stopped
networks:
- traefik
- internal
labels:
- traefik.enable=true
- traefik.docker.network=traefik
- traefik.http.routers.frontend.rule=Host(`${BASE_DOMAIN}`)${CUSTOM_DOMAIN:+ || Host(`${CUSTOM_DOMAIN}`)}
- traefik.http.routers.frontend.entrypoints=websecure
- traefik.http.routers.frontend.tls=true
- traefik.http.routers.frontend.tls.certresolver=letsencrypt
- traefik.http.services.frontend.loadbalancer.server.port=3000
networks:
traefik:
external: true
internal:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment