Run some sites directly by nginx without reverse proxy

JohnyByk

Verified User
Joined
Mar 7, 2012
Messages
251
I have configured DA to work with naginx as reverse proxy form apache:
webserver=nginx_apache


Is easy way to run sites belongs to some users without reverserse proxy - directly by nginx?
Some users hat sites optimized for nginx and they don't need apache.

Regards
 
Yes, it's easy to do this, but it might cause additional problems, because PHP is not directly loaded into nginx :) And the only mode supported would be PHP-FPM.
 
I'm using php-fpm. Can you tell me how to run site by nginx directly :)? I probably need to do a custom configuration for Nginx, or
maybe there is an easier way?
 
Last edited:
@smtalk I'm having the same question.I'd like to setup a static subdomain (static.[domain].ext) which is a symlink to a directory with only static files (images, css, js, icons, etc.) and I'd like to have requests to that specific subdomain being processed without apache, but only via nginx, while the main domain still handles the files via apache, like is possible in the latest Plesk release (see screenshot).

PS: I'm running PHP-FPM with apache_nginx, but I don't know how to "remove" the virtualhost section for that specific subdomain in Directadmin.
I already have tried to set the following in Custom HTTPD configuration > httpd.conf:
Code:
|*if SUB="static"|
|?WEBSERVER=nginx|
|?PHP=OFF|
|*endif|
but that doesn't work as I already expected.
Could you help me out a bit?
 

Attachments

  • Schermafbeelding 2020-06-20 om 09.18.02.png
    Schermafbeelding 2020-06-20 om 09.18.02.png
    172 KB · Views: 6
Back
Top