Docker images containing sql-migrate
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 2 commits ahead of thisiserico:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
examples/postgres
.travis.yml
Dockerfile
Dockerfile.postgres
Makefile
README.md
dbconfig.jq
entrypoint.sh

README.md

db-migration

Build Status Docker Container

quay.io/typeform/db-migration wraps sql-migrate within docker to easily run your containerized migrations.

Containerize your migrations

You'll need a directory with two elements:

  • A sql folder with all the sql migration files (check out the examples!)
sql
├── 00_setup.sql
└── 01_tables_creation.sql
  • A Dockerfile with just a couple lines
FROM quay.io/typeform/db-migration:postgres-9.6.4
COPY . .

After that, build the image and run a container:

docker build -t my-migrations .
docker run my-migrations up