Skip to content

Configuring Nginx

Arnold Noronha edited this page Sep 4, 2021 · 3 revisions

We suggest putting Screenshotbot behind an Nginx web server.

Simple configuration

server {
     listen 80;
     server_name mydomain.example.com;

     proxy_set_header Host $host:$server_port;
     proxy_set_header X-Real-IP $remote_addr;
     proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
     proxy_set_header X-Forwarded-Proto $scheme;

     location / {
          proxy_pass http://127.0.0.1:4091;
          proxy_redirect http://$proxy_host:$proxy_port https://$host;
     }
}

Clone this wiki locally