Skip to content

Commit

Permalink
Require OPcache with opcache.save_comments when installed
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonkelly committed Sep 9, 2023
1 parent 7a2d485 commit 445c8ec
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog for Craft CMS Server Check

## 2.1.6 - 2023-09-09
- Added a requirement for [`opcache.save_comments`](https://www.php.net/manual/en/opcache.configuration.php#ini.opcache.save-comments) to be enabled if OPcache is installed. ([craftcms/cms#13631](https://github.com/craftcms/cms/discussions/13631))

## 2.1.5 - 2023-05-26
- Fixed an error that could occur when running the requirements checker using PHP 8+.

Expand Down
8 changes: 8 additions & 0 deletions server/requirements/requirements.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,14 @@
'condition' => extension_loaded('mbstring') && ini_get('mbstring.func_overload') == 0,
'memo' => 'Craft CMS requires the <a rel="noopener" target="_blank" href="https://php.net/manual/en/book.mbstring.php">Multibyte String</a> extension with <a rel="noopener" target="_blank" href="https://php.net/manual/en/mbstring.overload.php">Function Overloading</a> disabled in order to run.'
),
array(
'name' => extension_loaded('opcache') ? 'OPcache extension (with save_comments)' : 'OPcache extension',
'mandatory' => extension_loaded('opcache'),
'condition' => extension_loaded('opcache') && ini_get('opcache.save_comments') == 1,
'memo' => extension_loaded('opcache')
? 'The <a rel="noopener" target="_blank" href="https://www.php.net/manual/en/opcache.configuration.php#ini.opcache.save-comments">opcache.save_comments</a> configuration setting must be enabled.'
: 'The <a rel="noopener" target="_blank" href="https://php.net/manual/en/book.opcache.php">OPcache</a> extension is recommended in production environments.'
),
array(
'name' => 'OpenSSL extension',
'mandatory' => true,
Expand Down

0 comments on commit 445c8ec

Please sign in to comment.