From 062ae4dbb221ed50ee64efc2e821b90e7d357a74 Mon Sep 17 00:00:00 2001 From: Boris Date: Mon, 30 Aug 2021 10:27:17 +0200 Subject: [PATCH] ENH: add Nginx conf for Astroport --- nginx.conf | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 nginx.conf diff --git a/nginx.conf b/nginx.conf new file mode 100644 index 0000000..f6ebade --- /dev/null +++ b/nginx.conf @@ -0,0 +1,39 @@ +server { + + root /home/pi/.zen/astrXbian/www/boris; + listen 80 default_server; + server_name _; + + # This section can be copied into an existing default setup + location / { + allow all; + index index.php index.html index.htm; + location ~ \.php { + try_files $uri index.php =404; + fastcgi_pass unix:/run/php/php7.3-fpm.sock; + fastcgi_index index.php; + fastcgi_param SCRIPT_FILENAME $request_filename; + include /etc/nginx/fastcgi_params; + fastcgi_read_timeout 1800; + } + error_page 404 = /error/404.html; + try_files $uri $uri/ =404; + location ~ /albumart/* { + expires -1s; + } + } + + + location /ipfs { + proxy_pass http://127.0.0.1:8181; + proxy_set_header Host $host; + proxy_set_header X-Forwarded-For $remote_addr; + } + + location /ipns { + proxy_pass http://127.0.0.1:8181; + proxy_set_header Host $host; + proxy_set_header X-Forwarded-For $remote_addr; + } + +}