Skip to content

Commit

Permalink
Add pgadmin container in docker-compose. (G-Research#37)
Browse files Browse the repository at this point in the history
* Add pgadmin container in docker-compose.

* update postgres
  • Loading branch information
sudiptob2 authored and dejanzele committed Jun 28, 2024
1 parent 96b64c5 commit c83a9e3
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 3 deletions.
22 changes: 19 additions & 3 deletions developer/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
services:
postgres:
container_name: postgres
image: postgres:15.2
image: postgres:15.7
hostname: postgres
# Either "host" or "bridge"
network_mode: "bridge"
# Either "linux/amd64" or "linux/arm64/v8" (e.g. Mac M1 systems)
platform: linux/arm64/v8
environment:
Expand All @@ -19,4 +17,22 @@ services:
retries: 3
start_period: 3s
timeout: 10s
networks:
- pgnetwork

pgadmin:
image: dpage/pgadmin4
environment:
- [email protected]
- PGADMIN_DEFAULT_PASSWORD=admin
ports:
- "5433:80"
depends_on:
- postgres
volumes:
- ./servers.json:/pgadmin4/servers.json
networks:
- pgnetwork

networks:
pgnetwork:
15 changes: 15 additions & 0 deletions developer/servers.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"Servers": {
"1": {
"Name": "YHS_Local",
"Group": "Servers",
"Host": "postgres",
"Port": 5432,
"MaintenanceDB": "yhs",
"Username": "yhs",
"Password": "yhs",
"SSLMode": "prefer",
"PassFile": "/pgadmin4/servers.json"
}
}
}

0 comments on commit c83a9e3

Please sign in to comment.