Fix docker-compose, add postgres init script

This commit is contained in:
Michael Hohn
2024-06-11 18:05:44 -07:00
committed by =Michael Hohn
parent 9c0cdb1fe4
commit 4b721b5969
3 changed files with 16 additions and 4 deletions

View File

@@ -9,7 +9,8 @@ services:
POSTGRES_PASSWORD: examplepass
POSTGRES_DB: exampledb
volumes:
- postgres_data:/Users/hohn/var/lib/postgresql/data
- postgres_data:/var/lib/postgresql/data
- ./postgres-init-scripts:/docker-entrypoint-initdb.d
ports:
- "5432:5432" # Exposing PostgreSQL to the host
expose:
@@ -38,7 +39,7 @@ services:
container_name: server
command: sh -c "apt-get update && apt-get install -y curl && tail -f /dev/null"
ports:
- "8080:80" # Exposing port 80 inside the container as port 8080 on the host
- "8080:8080"
volumes:
- /Users/hohn/work-gh/mrva/mrvacommander:/mrva/mrvacommander
depends_on: