Search the Community
Showing results for tags 'nginx'.
If you want to get rid of Apache and have your site working purely on Nginx, please consider these steps to migrate Apache-specific configurations into Nginx. NOTE: we do not support this officially. Apache + mod_rewrite will still be required for KVS and all functionality we add or change in KVS is always tested in Apache environment. We cannot guarantee these steps are everything you need to migrate to pure Nginx. Also we cannot guarantee that any future features will work in pure Nginx environment or will not require changes in Nginx configuration to make them working correctly. Nginx should set the following environmental variables which are typically set by Apache: REMOTE_ADDR SCRIPT_FILENAME SCRIPT_NAME REQUEST_METHOD QUERY_STRING REQUEST_URI DOCUMENT_ROOT These are typically set by default fastcgi configuration, but worth mentioning. You can find nginx rewrites in _INSTALL/nginx_config.txt file in your installation archive.
Please follow these steps to configure your VestaCP to use KVS Nginx rules. 1) Find out which rules you need first. Go to Settings -> Storage servers and open every storage that is located on this specific physical server (usually Local Videos and Local Albums). Each storage server displays Nginx config rules that you should add (storage servers for albums typically do not have any rules): Copy-paste all rules into the same text file one by one, if you have them from multiple storage servers. 2) Use WinSCP program to connect to your server via SFTP protocol as a root user. Open /home/admin/conf/web directory and create 2 text files in this directory: nginx.kvs-demo.com.conf_kvs snginx.kvs-demo.com.conf_kvs NOTE: replace kvs-demo.com with your domain name, you can see some similar files in this directory and you can check how your domain name is spelled in these files. Use the same spelling. Put the same nginx rules into both created files: the rules that you've copied on step 1. 3) Login to VestaCP with root account. Go to Server tab on the top. Find Nginx service, mouse over it and use restart option: 4) Finished. In order to check, go to Plugins -> System audit in KVS admin panel and run Installation, Servers and Content Protection checks. You should not have any errors and warning regarding content protection.