yum install php56-opcache
set opcache.revalidate_freq
to 0
in php.ini
or /etc/php.d/10-opcache.ini
Create a blacklist.txt
file somewhere on your filesystem (for example /etc/opcache-blacklist.txt
or /etc/php.d/opcache-default.blacklist
The file should contain items like:
/var/www/vhosts/site/app/views/*
/var/www/vhosts/site/app/controllers/*
/var/www/vhosts/site/public/index.php
; this is a comment
Edit /etc/php.ini
or /etc/php.d/10-opcache.ini
and add the line:
opcache.blacklist_filename=/etc/opcache-blacklist.txt
Restart apache / nginx