NC 12 X-Frame-Options Header and Opcache Error/Notice Fixes

Just wanted to share in one place fixes for whats seeming like common notices in Admin about headers and opcache in NC12.

FOR: X-Frame-Options header

If you are setting that header in your webserver config like everything I’ve read says you should have, you’ll get the notice in NC12 because that header is now in the code for “more dynamic control”.

So if you’re using nginx, remove or comment out “add_header X-Frame-Options “SAMEORIGIN”;” in your nginx conf file. Otherwise your config and NC code are both putting out the same header causing the values to be duplicated and no longer valid.

See: Release Notes — Nextcloud 12 Server Administration Manual 12 documentation

FOR: Opcache

I had it enabled in php.ini, but was still getting the notice about it not enabled. But with my php7 install, I had to edit the opcache.ini file. Once I copied values over to that file and restarted php-fpm, the notice went away.

See this post: Nextcloud 12 Beta 2 PHP Opcache is not properly configured - #17 by crazycloud

which is thanks to

Now have a “All checks passed.” :slight_smile: