Skip to content

Instantly share code, notes, and snippets.

@Keishake
Created April 14, 2015 11:24
Show Gist options
  • Save Keishake/06cb121d7de3e380a8a9 to your computer and use it in GitHub Desktop.
Save Keishake/06cb121d7de3e380a8a9 to your computer and use it in GitHub Desktop.
server {
listen 80;
server_name *.example.com>;
if ($host ~* "^([^.]+(\.[^.]+)*)\..example.com$"){
set $subd $1;
}
....
}
@otiai10
Copy link

otiai10 commented Apr 14, 2015

Thanks a lot! That's what I want 🙆‍♀️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment