Skip to content

Instantly share code, notes, and snippets.

@DarthSim
Created November 30, 2017 12:59
Show Gist options
  • Save DarthSim/ee75da7da21dc984fe5e99ac86509a9f to your computer and use it in GitHub Desktop.
Save DarthSim/ee75da7da21dc984fe5e99ac86509a9f to your computer and use it in GitHub Desktop.

Revisions

  1. DarthSim created this gist Nov 30, 2017.
    25 changes: 25 additions & 0 deletions imgproxy.conf
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,25 @@
    server {
    server_name your-domain.com;
    listen 443;

    client_max_body_size 8M;

    ssl on;
    ssl_certificate /path/to/your/cert.crt;
    ssl_certificate_key /path/to/your/cert.key;

    keepalive_timeout 60;
    ssl_session_timeout 5m;

    ssl_protocols SSLv2 SSLv3 TLSv1;
    ssl_ciphers ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP;
    ssl_prefer_server_ciphers on;

    location / {
    proxy_pass http://127.0.0.1:8080; # or whenever imgproxy is listening
    proxy_next_upstream error timeout invalid_header;
    proxy_set_header Host $host;
    proxy_set_header X-Forwarded-Proto http;
    proxy_redirect off;
    }
    }