Migrating to Mouf 2-beta 3 / Splash 4.2
Mouf 2 is getting near the stable release.
In the latest release, a few things have changed that might break your old application, so here is a very simple migration guide.
First of all, the ROOT_URL
constant is no more declared in config.php
. Instead, if you are using Splash, it will be automatically created for you.
When migrating, to Splash 4.2 and Mouf 2-beta 3, you will have an error message telling you that the 'ROOT_URL' constant is already defined.
In the /vendor/mouf/mouf
directory, delete the config.php
file. It was generated by a previous version of Mouf, is no more needed, and might prevent you from accessing the configuration management
page in Mouf.
The MoufUsers.php
file has moved. It is now in the mouf/no_commit
directory. Therefore, after upgrading, Mouf will ask you a reinstall. Just run the install process again by providing a login and password.
Also, when installing Splash 4.2, you will need to rewrite the .htaccess
file.
.htaccess
, go to Packages > Installation tasks, and reinstall the Write .htaccess file. task.The ROOT_URL is used by default in the APC cache service and the file cache service by default. You cannot anymore rely on those services. This means you must:
- Search for all UserService, ApcCache and FileCache instances
- Edit the prefix property and replace ROOT_URL by a random string. Ideally, you would create a "SECRET" constant in
config.php
, initialize it to some random value, and refer to this value.
Finally, you might want to commit your .htaccess file, since it is now the same file on all environments.
- david's blog
- Log in to post comments
What’s new on Mouf :
- TDBM 5.0 is released 09/11/2017
- Quickstarting a Mouf appl... 15/06/2017
- Building beautiful datagr... 05/10/2016
- Official release of TDBM... 14/06/2016
- Announcing Mouf 2.1 first... 01/03/2016
- Mouf + Magento + PSR-7 =... 30/06/2015
- Standardizing the way we... 10/06/2015
- Container interoperabilit... 09/06/2015
- Container-interop + PSR7... 01/06/2015
- New in Mouf: a console! 19/05/2015