Skip to content

Instantly share code, notes, and snippets.

@akopcz2
Created November 26, 2019 17:19
Show Gist options
  • Save akopcz2/b2da1a235fbb62e63e257a4f43cd59e1 to your computer and use it in GitHub Desktop.
Save akopcz2/b2da1a235fbb62e63e257a4f43cd59e1 to your computer and use it in GitHub Desktop.
NGINX echo shell
echo "
server {
listen 80;
server_name $1;
location / {
proxy_set_header X-Real-IP \$remote_addr;
proxy_set_header X-Forwarded-For \$remote_addr;
proxy_set_header Host \$host;
proxy_pass http://127.0.0.1:$2;
}
}" >> routes.conf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment