mautic / docker-mautic

Docker Image for Mautic
https://www.mautic.org
353 stars 268 forks source link

Mautic recreates the local.php file every time the service or container is restarted. #289

Closed alebak closed 3 weeks ago

alebak commented 3 weeks ago

Hello!

Every time the service that has the latest Mautic image (mautic:latest) is restarted it is recreating the local.php file, it does not take the previously configured environment variables and reloads the web installer. Apparently there are problems with this entrypoint file and the secret_key and site_url parameter is lost.

https://github.com/mautic/docker-mautic/blob/084bcee5cc963379a8c519fe2fad4df8eeb37615/common/entrypoint_mautic_web.sh#L12-L30

alebak commented 3 weeks ago

I have solved it. Apparently it is not enough to persist /var/www/html, you must also persist /var/www/html/config.