example-goose-pg-migration

module
v0.0.0-...-db07524 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 10, 2026 License: MIT-0

README

example-goose-pg-migration

Example project for migrating PostgreSQL database using the goose tool.

Prepare

git clone https://codeberg.org/kerbrek/example-goose-pg-migration.git
make _setup

Run

# first terminal
make compose

# second terminal
for run in {1..6}; do
  make pgmigrate-by-one
done
make _pgseed
make pgmigrate

Commands

Inspect Makefile content before running.

  • List all commands

    make help

  • Setup a working environment

    make _setup

  • Start Compose services

    make compose

  • Apply all Postgres migrations

    make pgmigrate

  • Migrate up a single Postgres migration from the current version

    make pgmigrate-by-one

  • Apply all Postgres seed migrations with no versioning

    make _pgseed

License

MIT No Attribution

Directories

Path Synopsis
cmd
pgmigrate command
pgseed command
postgres

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL