Skip to content

Commit 7c3be7e

Browse files
jklugeLSKpr
andauthored
Build (#24)
* Initial Dockerfiles * Docker Setup finalized * Remove some comments * Wrong app name * Small changes xD * Update .dockerignore * Always do npm ci * Updated docker --------- Co-authored-by: Kacper Lisik <lisik@kth.se>
1 parent c3266c8 commit 7c3be7e

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,7 @@ FROM node:18-alpine
22
WORKDIR /app
33
COPY my-app .
44
RUN npm ci
5+
ARG CI=false
6+
RUN if [ "$CI" = "true" ]; then npm run build; fi
57
EXPOSE 5173
68
CMD ["npm", "run", "dev"]

docker-compose.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ services:
22
app:
33
build:
44
context: .
5-
dockerfile: Dockerfile
5+
dockerfile: Dockerfile
6+
args:
7+
- CI=${CI:-false}
68
container_name: my-app
79
ports:
810
- "5173:5173"

0 commit comments

Comments
 (0)