Skip to content

Instantly share code, notes, and snippets.

@ejcx ejcx/nginx.conf
Last active Aug 11, 2016

Embed
What would you like to do?
Basic configuration for a global HTTP proxy.
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
log_format main '[$time_local] $scheme://$host$request_uri $status $http_user_agent';
server {
listen 80;
server_name localhost;
access_log /tmp/proxy.access.log main;
location ~ / {
resolver 8.8.8.8;
set $origin_server "$scheme://$host";
proxy_pass $origin_server;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.