<div> <br>as requested by Mr. Winters<br>here it is in public, my novice, mistakes ;(<br>/etc/nginx/sites-enabled# ls<br> default diaspora<br><br>default serves it's index page via IP<br> <br># Default server configuration<br>#<br>server {<br> listen 80 default_server;<br> listen [::]:80 default_server;<br><br> # SSL configuration<br> #<br> # listen 443 ssl default_server;<br> # listen [::]:443 ssl default_server;<br> #<br> # Note: You should disable gzip for SSL traffic.<br> # See: https://bugs.debian.org/773332<br> #<br> # Read up on ssl_ciphers to ensure a secure configuration.<br> # See: https://bugs.debian.org/765782<br> #<br> # Self signed certs generated by the ssl-cert package<br> # Don't use them in a production server!<br> #<br> # include snippets/snakeoil.conf;<br><br> root /var/www/html;<br><br> # Add index.php to the list if you are using PHP<br> index index.html index.htm index.nginx-debian.html;<br><br> server_name _;<br><br><br> location / {<br> # First attempt to serve request as file, then<br> # as directory, then fall back to displaying a 404.<br> try_files $uri $uri/ =404;<br> }<br><br> # pass PHP scripts to FastCGI server<br> #<br> #location ~ \.php$ {<br> # include snippets/fastcgi-php.conf;<br> #<br> # # With php-fpm (or other unix sockets):<br> # fastcgi_pass unix:/run/php/php7.3-fpm.sock;<br> # # With php-cgi (or other tcp sockets):<br> # fastcgi_pass 127.0.0.1:9000;<br> #}<br><br> # deny access to .htaccess files, if Apache's document root<br> # concurs with nginx's one<br> #<br> #location ~ /\.ht {<br> # deny all;<br> #}<br>}<br><br><br># Virtual Host configuration for example.com<br>#<br># You can move that to a different file under sites-available/ and symlink that<br># to sites-enabled/ to enable it.<br>#<br>#server {<br># listen 80;<br># listen [::]:80;<br>#<br># server_name example.com;<br>#<br># root /var/www/example.com;<br># index index.html;<br>#<br># location / {<br># try_files $uri $uri/ =404;<br># }<br>#}<br><br>However, diaspora via http://pod.non-mundane.org is 502 Bad Gateway<br><br>upstream diaspora_server {<br> server unix:/home/diaspora/diaspora/tmp/diaspora.sock;<br>}<br><br>server {<br> listen 80;<br> listen [::]:80;<br> server_name pod.non-mundane.org;<br> return 301 https://pod.non-mundane.org$request_uri;<br><br> access_log /dev/null;<br> error_log /dev/null;<br>}<br><br>server {<br> listen 443 ssl http2;<br> listen [::]:443 ssl http2;<br> server_name pod.non-mundane.org;<br><br> access_log /var/log/nginx/dspr-access.log;<br> error_log /var/log/nginx/dspr-error.log;<br><br> ssl_certificate /etc/letsencrypt/live/pod.non-mundane.org/fullchain.pem;<br> ssl_certificate_key /etc/letsencrypt/live/pod.non-mundane.org/privkey.pem;<br><br> ssl_protocols TLSv1.2;<br> ssl_ciphers EECDH+CHACHA20:EECDH+AESGCM:EECDH+AES;<br> ssl_ecdh_curve X25519:P-521:P-384:P-256;<br> ssl_prefer_server_ciphers on;<br> ssl_session_cache shared:SSL:10m;<br><br> root /home/diaspora/diaspora/public;<br><br> client_max_body_size 5M;<br> client_body_buffer_size 256K;<br><br> try_files $uri @diaspora;<br><br> location /assets/ {<br> expires max;<br> add_header Cache-Control public;<br> }<br> location @diaspora {<br> proxy_set_header X-Real-IP $remote_addr;<br> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;<br> proxy_set_header X-Forwarded-Proto https;<br> proxy_set_header Host $http_host;<br> proxy_redirect off;<br> proxy_pass http://diaspora_server;<br> }<br>}<br><br><br>--<br>MJ<br><br>Perhaps there were some small ommision in the HOWTO and Iam nu aware of things, as I can <br>use hand tools and weld etc, but programming is a higher challenge.<br><br>This is first test run on an ITX system. </div> <div class="yahoo_quoted" style="margin:10px 0px 0px 0.8ex;border-left:1px solid #ccc;padding-left:1ex;"> <div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;"> <div> On Sunday, 29 November 2020, 13:19:45 GMT, John Winters via GLLUG <gllug@mailman.lug.org.uk> wrote: </div> <div><br></div> <div><br></div> <div><div dir="ltr">On 29/11/2020 13:13, MJ wrote:<br clear="none">> Thank you John. I am humbled. I purposely did not include all info.<br clear="none">> domain:<br clear="none">> pod.non-mundane.org<br clear="none">> IP serving it:<br clear="none">> 209.93.50.226<br clear="none"><br clear="none">Please keep the conversation on the list.<br clear="none"><br clear="none">Interesting effect. As you say, accessing the IP address gives the <br clear="none">default Nginx page whilst going for the domain name gives a 502 error <br clear="none">generated by Nginx.<br clear="none"><br clear="none"><a shape="rect" ymailto="mailto:john@knight" href="mailto:john@knight">john@knight</a>:~$ host pod.non-mundane.org<br clear="none">pod.non-mundane.org has address 209.93.50.226<br clear="none"><a shape="rect" ymailto="mailto:john@knight" href="mailto:john@knight">john@knight</a>:~$<br clear="none"><br clear="none">The two match, so there must be some host-name specific configuration in <br clear="none">your Nginx setup.<br clear="none"><br clear="none">Let's see the contents of any files which you have put (or put symbolic <br clear="none">links to) in /etc/nginx/sites-enabled/.<div class="yqt5208642694" id="yqtfd82494"><br clear="none"><br clear="none">John<br clear="none"><br clear="none">-- <br clear="none">Xronos Scheduler - <a shape="rect" href="https://xronos.uk/" target="_blank">https://xronos.uk/</a><br clear="none">All your school's schedule information in one place.<br clear="none">Timetable, activities, homework, public events - the lot<br clear="none">Live demo at <a shape="rect" href="https://schedulerdemo.xronos.uk/" target="_blank">https://schedulerdemo.xronos.uk/</a><br clear="none"><br clear="none">-- <br clear="none">GLLUG mailing list<br clear="none"><a shape="rect" ymailto="mailto:GLLUG@mailman.lug.org.uk" href="mailto:GLLUG@mailman.lug.org.uk">GLLUG@mailman.lug.org.uk</a><br clear="none"><a shape="rect" href="https://mailman.lug.org.uk/mailman/listinfo/gllug" target="_blank">https://mailman.lug.org.uk/mailman/listinfo/gllug</a></div></div></div> </div> </div>