Skip to content

Instantly share code, notes, and snippets.

@tylerflint
Created July 31, 2015 21:04
Show Gist options
  • Save tylerflint/bdf522e52ab31721dcf0 to your computer and use it in GitHub Desktop.
Save tylerflint/bdf522e52ab31721dcf0 to your computer and use it in GitHub Desktop.
nanobox simple nginx config
# generate nginx config
cat > "$(payload 'build_dir')/etc/nginx/nginx.conf" <<END
daemon off;
worker_processes 1;
error_log /data/var/log/nginx/error.log;
events {
worker_connections 1024;
}
http {
include /data/etc/nginx/mime.types;
default_type application/octet-stream;
# access_log /data/var/log/nginx/access.log main;
keepalive_timeout 65;
gzip on;
server {
listen $(payload 'port');
server_name localhost;
location / {
root $(payload 'live_dir');
index index.html;
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
# error_page 500 502 503 504 /50x.html;
# location = /50x.html {
# root share/examples/nginx/html;
# }
}
}
END
@iampeterbanjo
Copy link

thanks

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