![]() |
VOOZH | about |
PostgreSQL is an open source object-relational database. Long-term versions maintained by Canonical.
500K+
ubuntu/postgres is a rock for postgres maintained by Canonical.
PostgreSQL is a powerful, open source object-relational database system. It has more than 20 years of active development and a proven architecture that has earned it a strong reputation for reliability, data integrity, and correctness.
NOTE: These tags follow a specific naming convention that respects the concept of channels.
| Tags | Supported until | Version | Base | Architectures | |
|---|---|---|---|---|---|
14-22.04_beta | - | 14 | 22.04 | s390x, amd64, ppc64le, arm64 | |
13-21.10_beta | - | 13 | 21.10 | amd64, s390x, arm64, ppc64le | |
13-21.04_beta | - | 13 | 21.04 | s390x, ppc64le, amd64, arm64 | |
12-20.04_beta | - | 12 | 20.04 | s390x, arm64, ppc64le, amd64 | |
16-24.04_edge | 04/2029 | 16 | 24.04 | arm64, amd64 |
This rock's entrypoint is Pebble, a container-optimized init process that enables the orchestration of a collection of local service processes as an organized set.
To view the Pebble services and checks defined in this rock:
docker run --rm ubuntu/postgres:14-22.04_beta plan
To run this rock, use any of the usual container runtimes, for example, docker:
docker run --name postgres-container \
-d -e TZ=UTC -e POSTGRES_PASSWORD=My:S3cr3t -p 30432:5432 \
ubuntu/postgres:14-22.04_beta
Access your PostgreSQL server at localhost:30432.
To view the logs of the running container, run:
docker exec postgres-container pebble logs
Or, for a specific service:
docker exec postgres-container pebble logs <service>
Rocks may have predefined health checks that you can list by running:
docker exec postgres-container pebble checks
The overall health of your container can be inspected via:
docker exec postgres-container pebble health
| Option | Description | Default |
|---|---|---|
| TZ | Timezone. | UTC |
| POSTGRES_PASSWORD | Set the password for the superuser (postgres by default). This option is mandatory and must not be empty. Required to connect from external hosts, e.g., my_secret_password. | None |
| POSTGRES_USER | Create a new user with superuser privileges, e.g., john. Used in conjunction with POSTGRES_PASSWORD. | None |
| POSTGRES_DB | Set the name of the default database, e.g., db_test. | None |
| POSTGRES_INITDB_ARGS | Pass arguments to the postgres initdb call, e.g., --data-checksums. | None |
| POSTGRES_INITDB_WALDIR | Set the location of the Postgres transaction log. By default it is stored in a subdirectory of the main Postgres data folder (PGDATA). | None |
| POSTGRES_HOST_AUTH_METHOD | Set the auth-method for host connections for all databases, all users, and all addresses. The following will be added to the pg_hba.conf if this option is passed 'host all all all $POSTGRES_HOST_AUTH_METHOD'. | None |
| PGDATA | Set the location of the database files. | /var/lib/postgresql/data |
| Option | Description | Default |
|---|---|---|
-v <path>:/etc/postgresql/postgresql.conf | Local configuration file postgresql.conf. | None |
-v <path>:/var/lib/postgresql/data | Persist data instead of initializing a new database every time you launch a new container. | None |
| Option | Description | Default |
|---|---|---|
-p <port>:5432 | Expose the container's port 5432 on the host's <port>. | None |
Canonical is the provider of this container image. It is the user's responsibility to ensure that any use of this image complies with any relevant licenses for all software contained within, as well as with Canonical’s IP Policy.
Content type
Image
Digest
sha256:11332e87f…
Size
199.8 MB
Last updated
2 days ago
docker pull ubuntu/postgres:16-24.04_edgePulls:
3,441
Jun 15 to Jun 21