Difference between revisions of "Subdomain"

From wikieduonline
Jump to navigation Jump to search
Line 3: Line 3:
  
  
 +
https://stackoverflow.com/questions/45318758/nginx-variable-for-subdomain
 +
  server {
 +
      [[listen]]      80;
 +
      [[server_name]]  ~^(?<my[[subdomain]]>.+)\.example\.com$;
 +
      [[return]]      301 http://example.com/$mysubdomain$[[request_uri]];
 +
  }
  
 
== See also ==
 
== See also ==

Revision as of 17:59, 26 August 2021

Advertising: