Tutorials

:: NGINX : Redirect to external URL

:: How to redirect to external url on NGINX
+ create configure file

vi /etc/nginx/vhosts/blackonsole.org.conf

added configuration like these:

server {
          listen 80;
          server_name blackonsole.org www.blackonsole.org;

          location / {
                 rewrite ^ //anotherurl.tld/path;
          }
}

+ testing configure file and reload nginx

nginx -t
nginx -s reload

 
:: Links
+ Google
+ Snipt

Hi, I’m Sysadmin.ID

Leave a Reply

Your email address will not be published. Required fields are marked *