This commit is contained in:
2023-06-11 22:44:25 +02:00
parent cafb6bc755
commit a38909babd
10 changed files with 1735 additions and 88 deletions

29
Dockerfile Normal file
View File

@@ -0,0 +1,29 @@
# Verwende Python als Basisimage
FROM node:latest
# Setze Arbeitsverzeichnis
WORKDIR /usr/src/app
# Kopiere die package.json und package-lock.json in das Arbeitsverzeichnis
COPY package*.json ./
# Installiere die Abhängigkeiten
RUN npm install
# Kopiere den Quellcode in das Arbeitsverzeichnis
COPY ./src .
# Installiere Python
RUN apt-get update && apt-get install -y python3 python3-pip
# Installiere die Python-Abhängigkeiten
RUN pip3 install --no-cache-dir -r requirements.txt
# Setze den Port des Web-Servers
ENV WEB_PORT=80
# Öffne den Port des Web-Servers
EXPOSE $WEB_PORT
# Starte den Web-Server
CMD ["python", "server.js"]