Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2 different files required w/ same relative path resolve to one file #227

Open
rob-odil opened this issue Dec 22, 2016 · 1 comment
Open

Comments

@rob-odil
Copy link

We have multiple ZF2 applications running on the same server. The ./public/index.php does a require of "config/application.config.php".

Zend\Mvc\Application::init(require 'config/application.config.php')->run();

Once that file is cached for one of the applications, the other applications all hit the same file in the opcode cache. Changing the require a full path using getcwd fixes this issue.

Zend\Mvc\Application::init(require getcwd() . '/config/application.config.php')->run();

@dstogov
Copy link
Contributor

dstogov commented Jan 9, 2017

opcache.use_cwd=1 in php.ini should solve the issue (1 is the default value).

opcache.revalidate_path=1 may help, if the problem caused by changes in symlinks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants