fixed docker compose anon changing node_modules ownership to root

This commit is contained in:
Aaro Koivukangas
2024-09-22 23:23:21 +03:00
committed by Aaro Koivukangas
parent 156d93a447
commit 0aaef4c40d
3 changed files with 35 additions and 31 deletions
+6 -11
View File
@@ -2,25 +2,20 @@
services:
frontend:
container_name: nowdb-frontend-anon
image: node:20-alpine3.16
volumes:
- ./frontend/:/usr/src/app
build:
context: ./frontend
dockerfile: Dockerfile
ports:
- 127.0.0.1:5173:5173
env_file: .anon.env
command: >
sh -c "cd /usr/src/app && npm ci && npm run dev -- --host"
backend:
container_name: nowdb-backend-anon
image: node:20-alpine3.16
env_file: .anon.env
volumes:
- ./backend/:/usr/src/app/backend/
- ./frontend/src/:/usr/src/app/frontend/src/
ports:
- 127.0.0.1:4000:4000
command: >
sh -c "cd /usr/src/app/backend && npm ci && npm run dev"
build:
context: .
dockerfile: ./backend/Dockerfile
db-anon:
container_name: nowdb-db-anon
image: mariadb:11.4.3