We're using "atomic" deploys where we symlink to the new version. Each time we do this, Craft thinks it's unlicensed. As we have allowAdminChanges
set to false
, this requires manually changing the general config file, going through the reactivation process (in the store). Clicking Reactivate resolves the issue and then we can set allowAdminChanges
to true again.
In point form, the deploy script:
- upload files excluding the
vendor
dir (and others that don't need to be on the server) to server in a new release dir (ie,releases/XXX
) - installs composer packages (we would typically do this on the docker instance, but Craft seems to install/make changes within the vendor dir, so that doesn't work, thus we install on directly on the server.
- moves the
/storage/rebrand
folder from the uploaded files from git into the shared (between releases) dir - symlink the
/storage
and/public/assets
dir from shared to their correct places in the current release - copy over the
.env
file - symlink to the new release
- run the following craft commands:
craft migrate/all
,craft project-config/apply
&craft clear-caches/all
The relevant commands are here: https://github.com/xmmedia/starter_craft/blob/master/.gitlab-ci.yml#L88-L99
Is there a command to reactivate the license from the CLI? Or is there something in that list that's screwing things up?