X-Git-Url: https://git.rapsys.eu/acme/blobdiff_plain/2a10253aea57d1e25280392a4f9b4e9420ece1b8..d17b7963e424d3574a4673e26ebd9aab38b741e6:/www/acme.nginx.conf diff --git a/www/acme.nginx.conf b/www/acme.nginx.conf new file mode 100644 index 0000000..4d807d1 --- /dev/null +++ b/www/acme.nginx.conf @@ -0,0 +1,19 @@ +server { + listen 80; + server_name example.com; + + root /usr/share/acme; + + location ~ ^/.well-known/acme-challenge { + rewrite ^/.well-known/acme-challenge/(.*)$ /acme-challenge.php?key=$1 last; + } + + location ~ ^/acme-challenge\.php$ { + fastcgi_pass unix:/tmp/php5-fpm.sock; + include fastcgi_params; + } + + location / { + return 301 https://$server_name$request_uri; + } +}