From 58ce76770728f2e61de3d30ff453cff8d054a4e0 Mon Sep 17 00:00:00 2001 From: Suresh Alse Date: Thu, 28 Apr 2016 11:33:06 -0700 Subject: [PATCH] Create nginx.md --- nginx.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 nginx.md diff --git a/nginx.md b/nginx.md new file mode 100644 index 0000000..6cd9a9c --- /dev/null +++ b/nginx.md @@ -0,0 +1,25 @@ +Hosting +======= + +Install [nginx](http://nginx.org/) on your server. Then edit the configuration to map port 80 (or any other port) to 8000 + +``` +sudo vi /etc/nginx/sites-available/default +``` +Change it to this +``` +server { + listen 80; + + server_name localhost; + + location / { + proxy_pass http://localhost:8000; + } +} +``` + +##Authentication + +You can enable basic http authentication with user name and password on nginx to prevent unauthorized users from accessing your cronjobs. Refer [this](https://www.digitalocean.com/community/tutorials/how-to-set-up-http-authentication-with-nginx-on-ubuntu-12-10). +