Initial commit
This commit is contained in:
13
Dockerfile
Normal file
13
Dockerfile
Normal file
@@ -0,0 +1,13 @@
|
||||
FROM node:20-alpine
|
||||
WORKDIR /app
|
||||
|
||||
# Nur package.json zuerst – npm install cached bleiben wenn sich nur Code ändert
|
||||
COPY package.json package-lock.json ./
|
||||
RUN npm ci --omit=dev
|
||||
|
||||
# Danach erst den Rest kopieren (node_modules wird NICHT kopiert dank .dockerignore)
|
||||
COPY server.js ./
|
||||
COPY public ./public
|
||||
|
||||
EXPOSE 3000
|
||||
CMD ["node", "server.js"]
|
||||
Reference in New Issue
Block a user