Skip to content

Instantly share code, notes, and snippets.

@varunyellina
Last active October 7, 2015 17:22
Show Gist options
  • Save varunyellina/44440f889479cb8d8628 to your computer and use it in GitHub Desktop.
Save varunyellina/44440f889479cb8d8628 to your computer and use it in GitHub Desktop.
Nginx configuration for dynamic resolution of site path, useful for development couple with dnsmasq.
server {
listen 80;
server_name ~^(?<localsite>\w+)\.dev$;
root /Users/varunyellina/Sites/$localsite;
access_log /usr/local/etc/nginx/logs/default.access.log;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment