Skip to content

Instantly share code, notes, and snippets.

@parsafatehi
Created November 7, 2021 07:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parsafatehi/2a1b47cd4b6c59595be3bc6b463856ed to your computer and use it in GitHub Desktop.
Save parsafatehi/2a1b47cd4b6c59595be3bc6b463856ed to your computer and use it in GitHub Desktop.
Redirect to a different domain - NGINX
# Redirect to a different domain
server {
server_name .domain1.com;
return 301 https://domain2.com$request_uri;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment