Skip to content

Commit

Permalink
chore: add client services to docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Lokrip committed Feb 14, 2025
1 parent ba86160 commit d6a8263
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 19 deletions.
24 changes: 12 additions & 12 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,18 @@ services:
depends_on:
- db-54321
web-app-client:
build:
context: .
dockerfile: docker/Dockerfile.client
ports:
- "3000:3000"
volumes:
- ".:/app"
command: >
sh -c "npm run dev"
depends_on:
- web-app
# web-app-client:
# build:
# context: .
# dockerfile: docker/Dockerfile.client
# ports:
# - "3000:3000"
# volumes:
# - ".:/app"
# command: >
# sh -c "npm run dev"
# depends_on:
# - web-app

db-54321:
container_name: db-54321-1
Expand Down
9 changes: 2 additions & 7 deletions docker/Dockerfile.client
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ FROM node:18-alpine
RUN apk add --no-cache libc6-compat
WORKDIR /app

COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* ./
COPY ./scripts/setup_dependencies_client.sh /app/scripts/setup_dependencies_client.sh
COPY package.json package-lock.json* /app/

RUN chmod +x /app/scripts/setup_dependencies_client.sh
RUN /app/scripts/setup_dependencies_client.sh
RUN npm install

COPY . .

Expand All @@ -19,6 +17,3 @@ EXPOSE 3000

ENV PORT 3000
ENV HOSTNAME "0.0.0.0"

RUN adduser --disabled-password nextjs
USER nextjs

0 comments on commit d6a8263

Please sign in to comment.