+1
Answered

nginx modules

louis-lau 9 years ago updated by CreativeWolf 8 years ago 8
How do i install an nginx module such as this one: http://wiki.nginx.org/NgxFancyIndex
with Ajenti V?

Answer

Answer
Answered

You can do this in the same way as normally - compile the module against NGINX headers, and paste those new directives into the custom configuration of a location in Ajenti V.

Heya all,


I have a similar situation of having to install ngx_http_realip_module and make nginx play along with CloudFlare - https://support.cloudflare.com/hc/en-us/articles/200170706-How-do-I-restore-original-visitor-IP-with-Nginx- Any idea how to achieve this with Ajenti please?


Thanks

Answer
Answered

You can do this in the same way as normally - compile the module against NGINX headers, and paste those new directives into the custom configuration of a location in Ajenti V.

Heya Eugene,


All the documents I read says compiling a module means reinstalling nginx, wouldn't that break anything and the existing site and setup in Ajenti?


Thanks for your response!


Cheers

You can use any kind of custom NGINX build, as long as it's using the same init script and the same config location as the standard build in your Linux distribution.

+1

I found the easiest way was to install my module was using the nginx-extras package. According to this document the realip module is also in there :)

https://docs.google.com/spreadsheet/ccc?key=0AjuNPnOoex7SdG5fUkhfc3BCSjJQbVVrQTg4UGU2YVE#gid=0

Eugene, Louis-lau,


I'm trying to understand this.


If I have to install a module, I will have to compile fresh nginx with modules and remove the existing one, which is tied with Ajenti.


I have 5 sites setup via Ajenti and I'm afraid if doing this will affect the setup that was done via Ajenti.


Sorta lost here, appreciate any help.


Thanks

In this case you don't need to go through the trouble of compiling. On any debian based os (Ubuntu for example), try running "sudo apt-get install nginx-extras". Restart nginx and the module is loaded :P

Louis-lau, Thank you. That just did the trick! Appreciate your help! :