Skip to content

Instantly share code, notes, and snippets.

@whomwah
Last active April 11, 2019 08:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save whomwah/94686 to your computer and use it in GitHub Desktop.
Save whomwah/94686 to your computer and use it in GitHub Desktop.
[Nginx] #nginx

Simple example of passing a short domain name over to a long one. Useful when url shortening

<VirtualHost *:80>
    ServerName short.me
    ServerAlias www.short.me
    ProxyPass / http://myverylongdomainname.com/
</VirtualHost>

Create HTTP password

htpasswd -c -d /etc/nginx/htpasswd duncan

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