Merge pull request #734 from Dahlgren/feature/docker

Basic Docker image for client app
This commit is contained in:
Pax1601 2024-01-03 09:18:28 +01:00 committed by GitHub
commit 59a9069d4b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 0 deletions

18
client/Dockerfile Normal file
View File

@ -0,0 +1,18 @@
FROM node:20-alpine AS appbuild
WORKDIR /usr/src/app
COPY package.json ./
COPY package-lock.json ./
RUN npm install
COPY . .
RUN npm run build-release-linux
FROM node:20-alpine
WORKDIR /usr/src/app
COPY package.json ./
COPY package-lock.json ./
RUN npm install --omit=dev
COPY . .
COPY --from=appbuild /usr/src/app/public ./public
EXPOSE 3000
CMD npm start

9
docker-compose.yml Normal file
View File

@ -0,0 +1,9 @@
version: '3'
services:
client:
build: client
ports:
- 3000:3000
volumes:
- ./olympus.json:/usr/src/olympus.json