0
Completed
How can i set my config for my website in Nginx Server?
Where i should put my config declarations for my website? I want to put this:
index index.php; error_page 404 /Page/System/404/; error_page 403 /403/; autoindex off; location / { if (-e $request_filename){ rewrite ^/(.+).css$ /min/css.php?file=$request_filename break; } if (!-e $request_filename){ rewrite ^/(.+) /xv.php/$1 break; } } location ~ ^(.*)\.(tpl|sql|tmp|config)$ { deny all; }But this didn't working on ajenti.
Answer
0
Answer
Completed
Eugene Pankov (Project coordinator) 11 years ago
Putting stuff in General > Custom Configuration will append it to the server { ... } directive. Put your index, error_page, location-deny configuration there. For your location /, put the rewrite configuration into Content > / > Custom Configuration, and it will be inserted into respective generated location { ... } block.
Answer
Completed
Putting stuff in General > Custom Configuration will append it to the server { ... } directive. Put your index, error_page, location-deny configuration there. For your location /, put the rewrite configuration into Content > / > Custom Configuration, and it will be inserted into respective generated location { ... } block.
How do I have to put "location / " into the Custom Configuration? Nginx says duplicate location...
If you already have "/" location in Content, put your location settings into Content > (content entry) > Advanced > Custom configuration instead.
Actually I have the same problem, even putting my custom config into its place, Ajenti overwrites the content, for example, I can not remove the "index index.html..." part, Ajenti puts it automaticaly, the same with location / even if I put my custom stuff, ajenti puts it's default stuff so I get duplicated things and that... weird
Now a "use custom configuration ONLY" option is available in Location settings.
Customer support service by UserEcho