diff --git a/omnibus/files/server-ctl-cookbooks/infra-server/resources/pg_sqitch.rb b/omnibus/files/server-ctl-cookbooks/infra-server/resources/pg_sqitch.rb index 998a0231ba..aeebafdbad 100644 --- a/omnibus/files/server-ctl-cookbooks/infra-server/resources/pg_sqitch.rb +++ b/omnibus/files/server-ctl-cookbooks/infra-server/resources/pg_sqitch.rb @@ -29,8 +29,7 @@ converge_by "Deploying schema from #{new_resource.name}" do execute "sqitch_deploy_#{new_resource.name}" do command <<-EOM.gsub(/\s+/, ' ').strip! - sqitch --engine pg - --db-name #{new_resource.database} + sqitch --db-name #{new_resource.database} --db-host #{new_resource.hostname} --db-port #{new_resource.port} --db-user #{new_resource.username} diff --git a/omnibus/partybus/lib/partybus/migration_api/v1.rb b/omnibus/partybus/lib/partybus/migration_api/v1.rb index d9e8476f9a..40cbd448ff 100644 --- a/omnibus/partybus/lib/partybus/migration_api/v1.rb +++ b/omnibus/partybus/lib/partybus/migration_api/v1.rb @@ -68,8 +68,7 @@ def run_command(command, options={}) def run_sqitch(target, service, opts = {}) options = default_opts_for_service(service).merge(opts) command = <<-EOM.gsub(/\s+/," ").strip! - sqitch --engine pg - --db-name #{options[:database]} + sqitch --db-name #{options[:database]} --db-host #{Partybus.config.postgres['vip']} --db-port #{Partybus.config.postgres['port']} --db-user #{options[:username]} diff --git a/src/bookshelf/habitat/config/database-migrations.sh b/src/bookshelf/habitat/config/database-migrations.sh index 3d703ea7dd..6316054956 100644 --- a/src/bookshelf/habitat/config/database-migrations.sh +++ b/src/bookshelf/habitat/config/database-migrations.sh @@ -34,4 +34,4 @@ createdb $PG_ARGS $DB "bookshelf" psql $PG_ARGS --command 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp"' $DB cd "{{pkg.path}}/schema" || exit -sqitch --quiet --engine pg deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" +sqitch --quiet deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" diff --git a/src/oc_bifrost/habitat/config/database-migrations.sh b/src/oc_bifrost/habitat/config/database-migrations.sh index 4ec4329c75..3def450553 100644 --- a/src/oc_bifrost/habitat/config/database-migrations.sh +++ b/src/oc_bifrost/habitat/config/database-migrations.sh @@ -34,4 +34,4 @@ createdb $PG_ARGS $DB "oc_bifrost" psql $PG_ARGS --command 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp"' $DB cd "{{pkg.path}}/schema" || exit -sqitch --quiet --engine pg deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" +sqitch --quiet deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" diff --git a/src/oc_bifrost/schema/Makefile b/src/oc_bifrost/schema/Makefile index ad33103947..2e357ae689 100644 --- a/src/oc_bifrost/schema/Makefile +++ b/src/oc_bifrost/schema/Makefile @@ -11,7 +11,7 @@ setup: @createdb $(TEST_DB) @psql --dbname $(TEST_DB) --command 'CREATE EXTENSION pgtap;' @psql --dbname $(TEST_DB) --single-transaction --set ON_ERROR_STOP=1 --file t/custom_test_functions.sql - @sqitch --engine pg --db-name $(TEST_DB) deploy + @sqitch --db-name $(TEST_DB) deploy @psql --dbname $(TEST_DB) --single-transaction --set ON_ERROR_STOP=1 --file sql/create_roles.sql @psql --dbname $(TEST_DB) --single-transaction --set ON_ERROR_STOP=1 --set database_name=$(TEST_DB) --file sql/permissions.sql diff --git a/src/oc_erchef/habitat/config/database-migrations.sh b/src/oc_erchef/habitat/config/database-migrations.sh index a0af3d00c1..a1f02fdd0d 100644 --- a/src/oc_erchef/habitat/config/database-migrations.sh +++ b/src/oc_erchef/habitat/config/database-migrations.sh @@ -34,7 +34,7 @@ createdb $PG_ARGS $DB "oc_bifrost" psql $PG_ARGS --command 'CREATE EXTENSION IF NOT EXISTS "uuid-ossp"' $DB cd "{{pkg.path}}/schema/baseline" -sqitch --quiet --engine pg deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" +sqitch --quiet deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" cd "{{pkg.path}}/schema" -sqitch --quiet --engine pg deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" +sqitch --quiet deploy "db:pg://${USER}:${PASS}@${HOST}/$DB" diff --git a/src/oc_erchef/schema/Makefile b/src/oc_erchef/schema/Makefile index cb645ccdab..6f808ed485 100644 --- a/src/oc_erchef/schema/Makefile +++ b/src/oc_erchef/schema/Makefile @@ -16,7 +16,7 @@ all : setup_schema setup_tests test setup_schema: $(MAKE) -C baseline setup_schema @echo "Deploying Enterprise Chef Server Schema on top..." - @sqitch --engine pg --db-name $(TEST_DB) deploy --verify + @sqitch --db-name $(TEST_DB) deploy --verify # Load up all testing functions. pgTAP libraries and open source # schema test functions are loaded by the open source makefile target diff --git a/src/oc_erchef/schema/baseline/Makefile b/src/oc_erchef/schema/baseline/Makefile index 81a6c215ca..550b0e62d1 100644 --- a/src/oc_erchef/schema/baseline/Makefile +++ b/src/oc_erchef/schema/baseline/Makefile @@ -8,7 +8,7 @@ setup_schema: @echo "Dropping and recreating database '$(TEST_DB)'" @psql --dbname template1 --command 'DROP DATABASE IF EXISTS $(TEST_DB)' @createdb $(TEST_DB) - @sqitch --engine pg --db-name $(TEST_DB) deploy + @sqitch --db-name $(TEST_DB) deploy setup_tests: @psql --dbname $(TEST_DB) --command 'CREATE EXTENSION pgtap;'