ezsystems / launchpad

CLI tool to bootstrap an eZ Platform project Docker stack | #justcode
https://ezsystems.github.io/launchpad
MIT License
22 stars 27 forks source link

Legacy Content Panels are empty when using eZ Launchpad on macOS with NFS #56

Closed SalvatorePollaci closed 5 years ago

SalvatorePollaci commented 5 years ago
Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? no
Version
Environment Mac

eZ Launchpad + Legacy Bridge + macOs + NFS is not compatible. The problem is that /ezpublish_legacy/kernel/classes/clusterfilehandlers/ezfsfilehandler.php uses php function 'flock' to gain exclusive access to ezmutex files. Unfortunately the php flock function calls the underlying flock system call which is not supported by NFS. Therefore no content cache files will be generated, and consequently, Legacy Content Panels will be empty.

If anyone has this problem, a dirty workaround if you are working in dev is to comment out the following lines in /ezpublish_legacy/kernel/classes/clusterfilehandlers/ezfsfilehandler.php:

// Lock the entry for exclusive access, if the entry does not exist
// it will be inserted with mtime=-1
if ( !$this->_exclusiveLock( $fname ) )
{
    // Cannot get exclusive lock, so return null.
    return null;
}
xserna commented 5 years ago

I can confirm this issue (I'm not on macOS, but one of my teammates). Legacy cache files are not created and due to this, legacy kernel has very strange behaviour: part of the pages not loaded, missing styles and javascripts...

Plopix commented 5 years ago

Can someone do a PR for this ? and a that to the documentation? Otherwise, I will at some point ;) This is not something we can nor will fix in Launchpad.

Plopix commented 5 years ago

Closing this issue, but documentation has to be done I will create another ticket.