refs #0 The root commit.
This commit is contained in:
49
docker-compose.yml
Normal file
49
docker-compose.yml
Normal file
@@ -0,0 +1,49 @@
|
||||
version: "3.3"
|
||||
|
||||
networks:
|
||||
shared:
|
||||
external: true
|
||||
|
||||
services:
|
||||
app:
|
||||
build: .
|
||||
container_name: library-back
|
||||
restart: always
|
||||
depends_on:
|
||||
- db
|
||||
env_file:
|
||||
- .env
|
||||
volumes:
|
||||
- ./back:/code
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
ports:
|
||||
- "127.0.0.1:8000:8000"
|
||||
user: "1000:1000"
|
||||
networks:
|
||||
- shared
|
||||
|
||||
front:
|
||||
image: node:latest
|
||||
container_name: library-front
|
||||
restart: always
|
||||
working_dir: /code
|
||||
volumes:
|
||||
- ./front:/code
|
||||
command: bash -c "npm install && npm run dev -- --host 0.0.0.0"
|
||||
ports:
|
||||
- "127.0.0.1:5173:5173"
|
||||
networks:
|
||||
- shared
|
||||
|
||||
db:
|
||||
image: postgres:latest
|
||||
container_name: library-db
|
||||
restart: always
|
||||
volumes:
|
||||
- ./postgres:/var/lib/postgresql/data
|
||||
env_file:
|
||||
- .env
|
||||
ports:
|
||||
- "127.0.0.1:5432:5432"
|
||||
networks:
|
||||
- shared
|
||||
Reference in New Issue
Block a user