Add initial setup for pgAdmin 4 with Docker and Nginx Proxy Manager

- Created .env.example for environment variable configuration.
- Added .gitignore to exclude sensitive files.
- Introduced config_local.py for pgAdmin settings.
- Added docker-compose.portainer.yml for service orchestration.
- Created Dockerfile for custom image building.
- Added README.md with setup instructions and usage guidelines.
- Included servers.json as a template for PostgreSQL server connections.
This commit is contained in:
Первов Артем
2026-04-16 11:53:55 +03:00
commit a992112d95
7 changed files with 275 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
services:
pgadmin:
image: dpage/pgadmin4:latest
restart: unless-stopped
environment:
TZ: ${TZ:-UTC}
PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL}
PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD}
PGADMIN_LISTEN_PORT: 80
PGADMIN_CONFIG_SERVER_MODE: ${PGADMIN_CONFIG_SERVER_MODE:-True}
PGADMIN_CONFIG_MASTER_PASSWORD_REQUIRED: ${PGADMIN_CONFIG_MASTER_PASSWORD_REQUIRED:-True}
PGADMIN_CONFIG_UPGRADE_CHECK_ENABLED: ${PGADMIN_CONFIG_UPGRADE_CHECK_ENABLED:-False}
PGADMIN_CONFIG_ENHANCED_COOKIE_PROTECTION: ${PGADMIN_CONFIG_ENHANCED_COOKIE_PROTECTION:-True}
volumes:
- pgadmin_data:/var/lib/pgadmin
- ./config_local.py:/pgadmin4/config_local.py:ro
- ./servers.json:/pgadmin4/servers.json:ro
expose:
- "${PGADMIN_PUBLISHED_PORT:-5050}:80"
healthcheck:
test: ["CMD-SHELL", "python3 -c \"import urllib.request; urllib.request.urlopen('http://127.0.0.1:80/misc/ping').read()\""]
interval: 30s
timeout: 10s
retries: 5
start_period: 40s
networks:
proxy:
external: true
networks:
internal:
driver: bridge
proxy:
external: true
volumes:
pgadmin_data:
name: ${PGADMIN_VOLUME_NAME:-pgadmin_data}