We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d12dec4 commit 25bb097Copy full SHA for 25bb097
‎Dockerfile
@@ -1,5 +1,7 @@
1
FROM node:20-alpine
2
3
+ARG LEETCODE_API_ENDPOINT
4
+
5
COPY ./packages/server/dist .
6
COPY ./packages/server/package.json .
7
COPY ./packages/asset/dist asset
‎packages/server/src/routers/leetcode/index.ts
@@ -1,12 +1,12 @@
import { Router } from "express";
-const ENDPOINT = "https://alfa-leetcode-api.onrender.com";
+const { LEETCODE_API_ENDPOINT = "http://localhost:3000" } = process.env;
const router = Router();
router.get("*", async (request, response) => {
8
try {
9
- const url = new URL(ENDPOINT);
+ const url = new URL(LEETCODE_API_ENDPOINT);
10
url.pathname = request.path;
11
for (const key in request.query) {
12
url.searchParams.append(key, request.query[key] as string);
0 commit comments