PostgreSQL 18.6 image with the OMDB sample database for teaching and SQL practice
246
This image provides a ready-to-use PostgreSQL 18.6 database containing the Open Media Database (OMDB) for teaching, SQL practice, and database experiments.
It is maintained by the DIIS Lab at Hochschule Düsseldorf and is primarily used in the module Datenbanksysteme 2.
OMDB (Open Media Database) is a freely available database containing information about movies, series, people, casts, categories, languages, countries, and related data.
The data originates from omdb.org and is imported into a normalized PostgreSQL schema based on the credativ/omdb-postgresql project.
The schema is intentionally only minimally optimized. Apart from primary keys, it contains no extensive set of indexes. This makes the database particularly useful for:
This image is intended as a convenient teaching and experimentation environment. No manual OMDB download or import is required.
The image is published as a multi-platform image for:
linux/amd64linux/arm64It can therefore be used on common Linux and Windows systems as well as Intel and Apple Silicon Macs running Docker.
2026.1-pg18.6Recommended tag for teaching environments.
It identifies both the OMDB teaching snapshot and the PostgreSQL version used by the image.
2026.1Convenience alias for the current 2026.1 teaching snapshot.
For reproducible teaching environments, using the full version tag is recommended:
diislab/dbs2-omdb:2026.1-pg18.6
Run the database with:
docker run -d \
--name dbs2-omdb \
-e POSTGRES_DB=omdb \
-e POSTGRES_USER=omdb \
-e POSTGRES_PASSWORD=omdb \
-p 127.0.0.1:54329:5432 \
-v dbs2_omdb_pg18:/var/lib/postgresql \
diislab/dbs2-omdb:2026.1-pg18.6
The OMDB snapshot is restored automatically when the database volume is initialized for the first time.
After the container has started, connect using:
| Setting | Value |
|---|---|
| Host | localhost |
| Port | 54329 |
| Database | omdb |
| User | omdb |
| Password | omdb |
These credentials are intentionally simple because this image is designed for local teaching and experimentation.
Do not use these credentials for production systems or expose this container directly to untrusted networks.
For teaching, Docker Compose is the recommended way to start the database.
Example compose.yaml:
name: dbs2-omdb
services:
postgres:
image: diislab/dbs2-omdb:2026.1-pg18.6
container_name: dbs2-omdb
environment:
POSTGRES_DB: omdb
POSTGRES_USER: omdb
POSTGRES_PASSWORD: omdb
ports:
- "127.0.0.1:54329:5432"
healthcheck:
test:
[
"CMD-SHELL",
"pg_isready -U omdb -d omdb && test -f \"$$PGDATA/.dbs2-omdb-ready\""
]
interval: 5s
timeout: 5s
retries: 60
volumes:
- dbs2_omdb_pg18:/var/lib/postgresql
volumes:
dbs2_omdb_pg18:
name: dbs2_omdb_pg18
Start the database with:
docker compose up -d
Check its status with:
docker compose ps
Stop the container while keeping the database volume:
docker compose down
To return to a clean OMDB snapshot, remove the container and its volume:
docker compose down -v
docker compose up -d
The database will then be initialized again from the snapshot included in the image.
Count all movies:
SELECT COUNT(*)
FROM movies;
Inspect some entries:
SELECT id, name, date, runtime
FROM movies
WHERE kind = 'movie'
ORDER BY date DESC NULLS LAST
LIMIT 10;
Explore the provided cast view:
SELECT *
FROM casts_view
LIMIT 10;
The database can be accessed with any PostgreSQL-compatible client, such as psql, DBeaver, DataGrip, or pgAdmin.
Within Datenbanksysteme 2, this image is mainly used as a lightweight SQL practice and reference database.
Students can use it to revisit concepts from introductory database courses (e.g. Datenbanksysteme 1) before working with larger and other specific databases used throughout later parts of the module.
The OMDB dataset may also be used occasionally for demonstrations where a compact relational dataset is more convenient than other complex examples.
The OMDB data originates from omdb.org (Open Media Database).
The PostgreSQL schema and import procedure are based on the open-source project credativ/omdb-postgresql.
According to the upstream project, the textual OMDB data is published under the Creative Commons Attribution 2.0 Germany (CC BY 2.0 DE) license.
The credativ/omdb-postgresql import tooling is independently developed by credativ and licensed under GNU GPL v2 or later.
This container image packages a PostgreSQL database snapshot generated from those sources for teaching purposes.
DIIS Lab
Hochschule Düsseldorf – University of Applied Sciences
Content type
Image
Digest
sha256:2fdc9155e…
Size
243.3 MB
Last updated
13 days ago
docker pull diislab/dbs2-omdb:2026.1