Thin wrapper around dpage/pgadmin4 to clear CAP_NET_BIND_SERVICE.
1.5K
OpenShift-friendly pgAdmin 4 container images with two variants:
Source code, Dockerfiles, and build automation are available on GitHub.
This is an independently maintained image and is not an official pgAdmin project image.
| Tag | Variant | Description |
|---|---|---|
<version> | Upstream-compatible | Official dpage/pgadmin4:<version> image with the capability-bearing Python binary removed. Published once per pgAdmin release. |
<version>-hardened | Hardened | Source rebuild of the corresponding pgAdmin release with refreshed OS and Python dependencies. Rebuilt regularly. |
latest | Hardened | Latest supported pgAdmin release using the hardened variant. |
For predictable deployments, pin a versioned tag instead of using latest.
docker run --rm \
-p 8080:8080 \
-e [email protected] \
-e PGADMIN_DEFAULT_PASSWORD='change-me' \
fyannk/pgadmin:latest
Open http://localhost:8080 and sign in using the configured credentials.
For production deployments, prefer PGADMIN_DEFAULT_PASSWORD_FILE with a mounted secret instead of putting the password directly in an environment variable.
apiVersion: apps/v1
kind: Deployment
metadata:
name: pgadmin
spec:
replicas: 1
selector:
matchLabels:
app: pgadmin
template:
metadata:
labels:
app: pgadmin
spec:
containers:
- name: pgadmin
image: docker.io/fyannk/pgadmin:latest
ports:
- name: http
containerPort: 8080
env:
- name: PGADMIN_DEFAULT_EMAIL
value: [email protected]
- name: PGADMIN_DEFAULT_PASSWORD
valueFrom:
secretKeyRef:
name: pgadmin-credentials
key: password
volumeMounts:
- name: data
mountPath: /var/lib/pgadmin
volumes:
- name: data
persistentVolumeClaim:
claimName: pgadmin
The images use an unprivileged port and are designed for restricted OpenShift environments. External access should be provided through a Service and Route.
The <version> tags stay close to the official pgAdmin image:
dpage/pgadmin4:<version>.8080 and 8443.Choose this variant when compatibility with the official image is the priority.
The <version>-hardened and latest tags are rebuilt from the matching upstream pgAdmin source release:
5050 by default.0.sudo, libcap, or capability-bearing Python binaries.Choose this variant when a smaller privilege footprint and regularly refreshed dependencies are preferred.
| Port | Purpose |
|---|---|
8080 | Default HTTP listener |
8443 | Default HTTPS listener |
Set PGADMIN_LISTEN_PORT to use another unprivileged port.
The images intentionally do not include the capability required to bind directly to ports below 1024. Use container port mapping, a Kubernetes Service, or an OpenShift Route for ports 80 and 443.
Mount persistent storage at:
/var/lib/pgadmin
Make sure the volume is writable by the container UID or by GID 0 when using OpenShift arbitrary UIDs.
A new installation normally requires:
PGADMIN_DEFAULT_EMAIL
PGADMIN_DEFAULT_PASSWORD
Where supported, use:
PGADMIN_DEFAULT_PASSWORD_FILE
See the official pgAdmin container documentation for additional runtime configuration.
These images remove privileged-port support, but no container image can guarantee a permanent zero-vulnerability result.
The hardened variant is rebuilt regularly to consume available Alpine and Python security updates. Findings without an available vendor fix should be assessed according to your organisation's vulnerability-management policy.
Always scan the exact image digest you intend to deploy.
Content type
Image
Digest
sha256:134db0f1e…
Size
147.5 MB
Last updated
about 1 month ago
docker pull fyannk/pgadmin