Custom Web Service Configurations

In by Matthew Lear

This article describes how to apply custom nginx and php configurations to the MediaCP.

Custom Web Server changes

The MediaCP uses Nginx Web Server and as such your changes must be compatible with Nginx.

Direct changes to nginx configuration files outside of the conf.d file will be lost on upgrade.

You should apply any custom configurationsĀ to a new file with .conf extension inside the following folder:

/usr/local/mediacp/nginx/conf.d/

For example,

# nano /usr/local/mediacp/nginx/conf.d/50_mychange.conf

These changes are included in the nginx server {} block

After applying changes, you will need to restart the MediaCP services:

/usr/local/mediacp/service restart

Custom PHP.ini changes

Direct changes to php.ini configuration file will be lost on upgrade.

You should apply any custom php.ini configurations to the php.include file:

/usr/local/mediacp/php/php.d/custom.ini

After applying changes, you will need to restart the MediaCP services:

/usr/local/mediacp/service restart