Activities

August 2020
M T W T F S S
« Apr    
 12
3456789
10111213141516
17181920212223
24252627282930
31  

NGINX : http domain requests to www

How do I re-direct the http domain request www domain request in Nginx server.

You need to add two virtualhost. One is for re-directing non-www request and other one is for server www-domain request.

# [root@u15382543 ~]# vi /etc/nginx/conf.d/domain.com.conf

server {    server_name  domain.com;    listen    74.28.17.98:80;     rewrite ^(.*) http://www.domain.com$1 permanent; } […]

Nginx : Setting up custom error pages

Add the following line in your virtualhost config. file for your domain.

error_page 500 502 503 504 404  /404.html;         location = /404.html {          root  /var/www/vhosts/mydomain.com/httpdocs/;      }

Pls note that you have a file created on httpdocs named “404.html”. For setting this up on a joomla […]

Nginx -Apache -Proxy configuration on Centos-Plesk server

Question, My requirements are,

1. I have few very high traffic websites and I need to get maximum performance to the users on the peak time and my web server should serve the pages as must faster than Apache does. 2. Apache is primary server and heavy loaded and pages are loaded slowly on […]