Adding setup for postgres docker compose + connection from app.
This commit is contained in:
parent
4282cc4b12
commit
fad73f26de
3 changed files with 47 additions and 0 deletions
11
2024/07/golang_demo1/docker_compose.yml
Normal file
11
2024/07/golang_demo1/docker_compose.yml
Normal file
|
@ -0,0 +1,11 @@
|
|||
services:
|
||||
db:
|
||||
image: postgres:11
|
||||
ports:
|
||||
- '5432:5432'
|
||||
volumes:
|
||||
- '/opt/db_data:/var/lib/postgresql/data'
|
||||
environment:
|
||||
POSTGRES_PASSWORD: pass
|
||||
POSTGRES_DB: repo
|
||||
POSTGRES_USER: db_user
|
Loading…
Add table
Add a link
Reference in a new issue