Compare commits

...

2 Commits

Author SHA1 Message Date
Julien Calixte
f2bd71183f chore(cors): update frontend URL to apoena.dev domain 2026-04-22 14:11:59 +02:00
Julien Calixte
e1aa33fa7b fix(docker): use PORT env var in healthcheck 2026-04-22 14:11:57 +02:00
2 changed files with 2 additions and 2 deletions

View File

@@ -26,7 +26,7 @@ USER denouser
# Health check # Health check
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \ HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
CMD deno eval "fetch('http://localhost:8000/health').then(r => r.ok ? Deno.exit(0) : Deno.exit(1))" || exit 1 CMD deno eval "fetch('http://localhost:' + (Deno.env.get('PORT') || '8000') + '/health').then(r => r.ok ? Deno.exit(0) : Deno.exit(1))" || exit 1
# Run the application # Run the application
CMD ["deno", "run", "--allow-net", "--allow-env", "src/main.ts"] CMD ["deno", "run", "--allow-net", "--allow-env", "src/main.ts"]

View File

@@ -5,7 +5,7 @@ const DEEPL_API_KEY = Deno.env.get("DEEPL_AUTH_KEY");
const BEARER_TOKEN = Deno.env.get("BEARER_TOKEN"); const BEARER_TOKEN = Deno.env.get("BEARER_TOKEN");
const PORT = parseInt(Deno.env.get("PORT") || "8000"); const PORT = parseInt(Deno.env.get("PORT") || "8000");
const DEEPL_API_BASE = "https://api-free.deepl.com/v2"; const DEEPL_API_BASE = "https://api-free.deepl.com/v2";
const FRONTEND_URLS = ["http://localhost", "https://deep-lite.netlify.app"]; const FRONTEND_URLS = ["http://localhost", "https://deeplite.apoena.dev"];
if (!DEEPL_API_KEY) { if (!DEEPL_API_KEY) {
console.error("ERROR: DEEPL_AUTH_KEY environment variable is required"); console.error("ERROR: DEEPL_AUTH_KEY environment variable is required");