Containerized PostgreSQL Database for a Finance App
Overview
A Docker packaging of a PostgreSQL database for a finance application, building a custom image that ships pre-seeded data and is published to a private GitLab Container Registry for repeatable deployment.
Why It Exists
To make a finance app’s database environment portable and reproducible, one docker-compose up brings up Postgres with the expected schema and seed data, rather than relying on manual restores.
What We Built
- A
Dockerfileextending Postgres and abackup.sqldump baked into the image. - A
docker-compose.ymlreferencing the custom registry image (registry.gitlab.com/...) and configuring the database environment. - A
build.shto build and push the image to the private registry, with a.dockerignoreto keep the context lean.
Technologies & Approach
Docker and docker-compose with PostgreSQL; the image is distributed via GitLab’s container registry so the same database state can be pulled anywhere in the pipeline.
Outcome / Impact
Delivered a portable, version-controlled database environment for a finance application, demonstrating the practice of treating data infrastructure as a reproducible, registry-distributed artifact.
Capabilities Demonstrated
- Building reproducible, seed-baked database container images
- Distributing infrastructure via a private container registry
- Composing local environments with docker-compose