Why do we have a different php.ini for the php client ?
Is it a good idea to link the main instead ?
$ sudo ln -s /etc/php5/apache2/php.ini /etc/php5/cli/php.ini
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.
Sign up to join this communityIt entirely up to you how you configure your system, based on your needs. However, there are good reasons for having separate configuration files for CLI and Apache, not least because a web server is typically an externally facing service. For example:
Note that you can also configure your PHP installation by adding files to /etc/php5/conf.d
. This is a good way to keep your customisations in their own file and avoid conflicts in your php.ini
file(s) if they get updated by a new version of the packages. The latter point is also an issue if you choose to use symlinks for php.ini
. Note that the conf.d
directories for cli
and apache
are symlinks.