[NGINX] Redirect to another domain - fourslickz/notes GitHub Wiki

nginx.conf

server {
  server_name .mydomain.example;
  return 301 http://anotherdomain.example$request_uri;
}