/
WebsiteSupport

DocsDeveloper guideWorked example

Install and activate

Upload puts the files in place. Activate runs the migrations and switches the add-on on. They are two steps on purpose.

1 min read

  1. Upload: Settings > Apps & Features, Upload package (an administrator only). The archive is checked, hash-checked in a staging folder and only then moved into app/Addons (app/Http/Controllers/AppLifecycleController.php:131-161, app/Support/Addons/AddonPackage.php:62, :356-365). Upload does NOT activate (app/Support/Addons/AddonPackage.php:53-60).
  2. Activate: from the add-on's card, or on the server with php artisan addon:app activate <slug> (app/Console/Commands/AddonAppCommand.php:13-58). Both run AddonLifecycle::activate (app/Support/Addons/AddonLifecycle.php:34): it checks depends, runs the migrations, writes the installed row and copies the bundle (app/Support/Addons/AddonInstaller.php:238-278).
  3. Deactivate keeps the data; Uninstall drops it (app/Support/Addons/AddonLifecycle.php:197, :216).
  4. Check: php artisan addon:app status <slug> lists the version, state, own migrations run and dependencies (app/Console/Commands/AddonAppCommand.php:25-37).

See also