diff --git a/backend/execution-worker/execute.js b/backend/execution-worker/execute.js index 55a011e..4db3a1e 100644 --- a/backend/execution-worker/execute.js +++ b/backend/execution-worker/execute.js @@ -81,7 +81,6 @@ const executeFromQueue = async (message, channel) => { return; } resolve(); - console.log("TLE"); didTLE = true; const result = { status: "TimeLimitExceeded", @@ -193,7 +192,6 @@ const executeFromQueue = async (message, channel) => { points: true, }, }); - console.log(updated.points); } } }; diff --git a/backend/middlewares/rate-limit.js b/backend/middlewares/rate-limit.js index d68976f..56f1b88 100644 --- a/backend/middlewares/rate-limit.js +++ b/backend/middlewares/rate-limit.js @@ -14,7 +14,6 @@ const rateLimit = async (req, res, next, limit = 5, use = "") => { req.socket.remoteAddress || req.connection.socket.remoteAddress; } - console.log(key); const redisId = `rate-limit:${use}/${key}`; const requests = await redis.incr(redisId); if (requests === 1) { diff --git a/code-runner/Dockerfile b/code-runner/Dockerfile index 26ccdb8..8ffeb94 100644 --- a/code-runner/Dockerfile +++ b/code-runner/Dockerfile @@ -1,11 +1,12 @@ -FROM ubuntu:latest +FROM alpine:latest WORKDIR /usr/code-runner -RUN apt update -RUN apt install gcc g++ -y -RUN apt install nodejs -y -RUN apt install python3 -y -RUN apt install default-jdk -y +RUN apk update +RUN apk add gcc g++ +RUN apk add nodejs +RUN apk add python3 +RUN apk add openjdk11 +RUN apk add bash COPY executor.py executor.py CMD ["bash"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 421d1d7..949435f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,8 +10,8 @@ services: volumes: - ./backend/.env.prod:/usr/src/app/.env - /var/run/docker.sock:/var/run/docker.sock - # - /path/to/ssl/fullchain.pem:/usr/src/app/ssl/fullchain.pem - # - /path/to/ssl/privkey.pem:/usr/src/app/ssl/privkey.pem + - /path/to/ssl/fullchain.pem:/usr/src/app/ssl/fullchain.pem + - /path/to/ssl/privkey.pem:/usr/src/app/ssl/privkey.pem user: root command: sh -c "npx prisma migrate deploy && npm run start" diff --git a/frontend/src/components/custom/Editorials.jsx b/frontend/src/components/custom/Editorials.jsx index 135e5bd..ba3c9ec 100644 --- a/frontend/src/components/custom/Editorials.jsx +++ b/frontend/src/components/custom/Editorials.jsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from "react"; +import React from "react"; import { ScrollArea } from "../ui/scroll-area"; import { Table, @@ -8,7 +8,7 @@ import { TableHeader, TableRow, } from "../ui/table"; -import { ArrowLeft, DeleteIcon, Edit } from "lucide-react"; +import { ArrowLeft, DeleteIcon } from "lucide-react"; import Markdown from "react-markdown"; import { Button } from "../ui/button"; @@ -23,13 +23,6 @@ function Editorials({ return (