Phinx is migration tool for SQL databases, written in Php. This is highly efficient migration tool.
1.2K
Github: https://github.com/uzrnem/phinx-php-cakephp
MySQL: specify the mysql adapter.
PostgreSQL: specify the pgsql adapter.
SQLite: specify the sqlite adapter.
SQL Server: specify the sqlsrv adapter.
Please raise MR for this adapter
version: "3.7"
services:
phinx:
image: uzrnem/phinx:0.1
container_name: phinx
volumes:
- $PWD/db:/phinx/db
environment:
PHINX_DB_HOST: mysqlhost
PHINX_DB_DATABASE: mydb
PHINX_DB_USERNAME: postgres
PHINX_DB_PASSWORD: changeme
version: "3.7"
services:
phinx:
image: uzrnem/phinx:0.1
container_name: phinx
volumes:
- $PWD/db:/phinx/db
environment:
PHINX_DB_ADAPTER: pgsql
PHINX_DB_HOST: postgresdb
PHINX_DB_DATABASE: mydb
PHINX_DB_USERNAME: postgres
PHINX_DB_PASSWORD: changeme
PHINX_DB_PORT: 5432
./vendor/bin/phinx create PostsTableMigration
./vendor/bin/phinx migrate
./vendor/bin/phinx rollback
./vendor/bin/phinx status
./vendor/bin/phinx seed:create UserSeeder
./vendor/bin/phinx seed:run -v
$this->table('posts')->drop()->save();
$table = $this->table('posts');
$table->rename('articles')
->update();
$table = $this->table('posts');
$table->changePrimaryKey('new_primary_key');
$table->update();
Content type
Image
Digest
sha256:2fb7b5ad7…
Size
191.4 MB
Last updated
almost 3 years ago
docker pull uzrnem/phinx