Runs migrations automatically

Installs: 14 470

Dependents: 1

Suggesters: 0

Security: 0

Stars: 4

Watchers: 3

Forks: 0

Open Issues: 0


2.5.0 2022-11-08 08:39 UTC


A Composer plugin that runs craft migrate/all and craft project-config/apply after composer install, if Craft is installed.


Require the package as a dependency of a plugin or in the composer.json of your project.

composer require fortrabbit/craft-auto-migrate


By setting the ENV var DISABLE_CRAFT_AUTOMIGRATE=1 you disable the plugin.

Project Config

By setting the ENV var PROJECT_CONFIG_FORCE_APPLY=1 the project-config/apply command is executed with the --force flag.

The file config/project/project.yaml will be removed after applying, unless you set the ENV var KEEP_PROJECT_CONFIG=1 or composer install is running locally (interactive mode). This behaviour was added in 2.5.0 to prevent re-applying the Project Config in the Craft CP.