Overview
We use Nginx as the main web server in Cito. Each site has it’s main nginx configuration in/etc/nginx/conf.d/ - the file will end in .conf.
Note there may also be *.conf.dist files in this directory- these are example files for specific apps (wordpress/laravel/magento etc) and are not active- by default nginx only parses .conf files. These are required and should not be removed.
Redirects are stored in /etc/nginx/redirects/ - if making custom changes to redirects, you should store them in this file.
We recommend against making manual modifications to your nginx configuration files; these are automatically generated and managed by Cito, and so unmanaged changes can have undesirable consequences.
Making configuration changes
To validate your configuration change before applying it, runnginx -t. If there’s an error, nginx will warn you:
systemctl reload nginx.
