diff --git a/docs/nginx.md b/docs/nginx.md index 2ea2138..fa56c1a 100644 --- a/docs/nginx.md +++ b/docs/nginx.md @@ -147,46 +147,47 @@ 4. Open *(or duplicate the configuration)* and edit it: * Example configuration, again: ```sh - server { - access_log /dev/null; # Search log file. Do you really need to? - error_log /dev/null; # Error log file. + server { + access_log /dev/null; # Search log file. Do you really need to? + error_log /dev/null; # Error log file. - # Change this if you have 4get in another folder. - root /var/www/4get; - # Change 'onionadress.onion' to your onion link. - server_name onionadress.onion; - # Port to listen to. - listen 80; - - location @php { - try_files $uri.php $uri/index.php =404; - # Change the unix socket address if it's different for you. - fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock; - fastcgi_index index.php; - # Change this to `fastcgi_params` if you use a debian based distribution. - include fastcgi.conf; - fastcgi_intercept_errors on; - } - - location / { - try_files $uri @php; - } - - location ~* ^(.*)\.php$ { - return 301 $1; - } + # Change this if you have 4get in another folder. + root /var/www/4get; + # Change 'onionadress.onion' to your onion link. + server_name onionadress.onion; + # Port to listen to. + listen 80; + location @php { + try_files $uri.php $uri/index.php =404; + # Change the unix socket address if it's different for you. + fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock; + fastcgi_index index.php; + # Change this to `fastcgi_params` if you use a debian based distribution. + include fastcgi.conf; + fastcgi_intercept_errors on; } + + location / { + try_files $uri @php; + } + + location ~* ^(.*)\.php$ { + return 301 $1; + } + + } ``` A real world example is present in [^2]. 5. Once done, check the configuration with `nginx -t`. If everything's fine and dandy, refer to the Tor guide to setup your onion site.