Supported databases:
- PostgreSQL;
Docker:
docker run --rm -v/path/to/migrations:/migrations borodyadka/db-migrate up -d postgres://user:pass@host:5432/database
CLI:
migrate up -d postgres://user:pass@host:5432/database -s /path/to/migrations
Commands:
up [n]— apply migrations, defaultnisMaxInt32down [n]— revert migrations, defaultnis1create <name>— create new migrationtest— tests connection
DATABSE_URLor--db-url/-din formatpostgres://user:pass@host:5432/database?sslmode=disableHISTORY_TABLEor--history-table/-t, default ismigrations_historyLOG_LEVELor--verbosity/-vone ofdebug,info,warning,errorSOURCE_DIRor--source/-spath to migrations dir, default is pwd
- tests