Difference between revisions of "Server name"

From wikieduonline
Jump to navigation Jump to search
(Created page with "http://nginx.org/en/docs/http/server_names.html == See also == * {{nginx}} Category:Web")
 
 
(5 intermediate revisions by the same user not shown)
Line 2: Line 2:
  
  
 +
* <code>server_name</code>
 +
* <code>server_name _;</code>
  
 +
 +
https://stackoverflow.com/questions/45318758/nginx-variable-for-subdomain
 +
server {
 +
    [[listen]]      80;
 +
    server_name  ~^(?<name>.+)\.example\.com$;
 +
    [[return]]      301 http://example.com/$name$[[request_uri]];
 +
}
  
 
== See also ==
 
== See also ==
 +
* {{nginx.conf}}
 
* {{nginx}}
 
* {{nginx}}
  
 
[[Category:Web]]
 
[[Category:Web]]

Latest revision as of 17:49, 26 August 2021

Advertising: