I'm following some third part projects developed with octobercms version 1.0. If I need to remove a plugin in locale is quite easy: 'php artisan plugin:remove' and it removes all plugin tables from the db and all the files. With the versioning control system I update the production and then the plugin dir and all the files are removed. But what about the db? How can I sync the production db without doing it manually?
This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.
Hi Bob,
Take a look at this configuration item in the config/system.php file:
/*
|--------------------------------------------------------------------------
| Automatically Rollback Plugins
|--------------------------------------------------------------------------
|
| Attempt to automatically reverse database migrations for a plugin when
| they are uninstalled using composer. This is disabled by default
| to prevent data loss.
|
*/
'auto_rollback_plugins' => env('AUTO_ROLLBACK_PLUGINS', false),
Set this value to true and it should attempt to rollback your plugin in the database before the package is removed by composer.
You may also manually rollback a plugin before removing it via composer using the plugin:refresh command.
php artisan plugin:refresh Acme.Demo --rollback
I hope this helps
1-4 of 4