Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have nginx as the front proxy server, All traffics go through that, and on the same machine I need to run PHP so the quick easy way was running apache.

I only enabled SSL on nginx so things are running with HTTPS, is it safe? Having both running on SSL seems odd, resource inefficient.

share|improve this question
Yes, but nginx can serve as the origin server and run PHP perfectly well (many of us would say better than Apache). You can probably safely eliminate Apache with an nginx + php-fpm setup. – Michael Hampton Aug 16 '12 at 6:11
up vote 2 down vote accepted

Having SSL running on only Nginx is a safe way to do things. To intercept traffic the attacker would need to have access to your local machine.

Running SSL on both Nginx and Apache is a waste of resources, it's no point in encrypting traffic between load balancer and your application server that in this case are Apahce.

share|improve this answer

I only enabled SSL on nginx so things are running with HTTPS, is it safe?

Yes, it is perfectly safe to run nginx as an SSL-terminator in front of Apache.

However, both Apache and nginx are able to run HTTPS and PHP, so for simplicity you can either move the HTTPS to Apache or PHP to nginx if you'd like.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.