Forums

Unfortunately no one can be told what FluxBB is - you have to see it for yourself.

You are not logged in.

#1 2020-06-10 23:10:13

bigtester
New member
Registered: 2020-06-10
Posts: 2

accessing install.php for new install of 1.5.11 on home server (nginx)

hi all <3 I'm trynta install that good ol fluxbb 1.5.11 on my home server (ubuntu server 20.04, nginx), but I'm running into problems *getting to* install.php. Here's what I mean:

I have a website (call it example.com) hosted on a VPS, somewhere. I'm trying to configure some webapps that are hosted locally, but accessible via the subdomains of example.com. I have one already working, as follows: an A-record on example.com redirects foo.example.com to the WAN IP of my router, which then forwards ports through NAT to my home server (local IP 192.168.1.69) running nginx. The config file foo.example.com.conf gets accessed in /etc/nginx/sites-enabled (via symlink to a conf file in /etc/nginx/sites-available), and, bada bing bada boom, the thing works.

I'm now trying to set up bar.example.com to work in the same way. (I haven't set up the A-record for bar.example.com yet, for obvious reasons.) I got PHP and MySQL installed on the box, made a little database for it, y'know the drill. I then downloaded 1.5.11, unzipped it, moved the contents to /usr/www/bar.example.com. Then I moved to /etc/nginx/sites-available, and set up an extremely barebones configuration file that I barely understand (attached below). I set up a symlink to sites-enabled, reloaded nginx, confirmed that 192.168.1.69 shows the nginx splash screen, and now just needed to get to install.php...

...but the problem is, I don't know how to get there. I can access it from command line on my server machine, but it just prints the php of the webpage I'd like to be visiting — no use to me! So I'd like to access it from my client computer (on the LAN) but bar.example.com/install.php automatically resolves to the DNS of example.com, which doesn't exist yet, so it returns 404. And 192.168.1.69/install.php returns nothing, which I figure happens because 192.168.1.69 (and its ports) would be doing double-duty for these two webapps (foo and bar, the former of which already works).

(Worth noting here that I haven't put any specialized configuration into nginx.conf directly, which might be needed here; I also want to keep my nginx build as modular as possible, with as few things hardcoded into nginx.conf as possible, so that the individual .conf files of the webapps can do the heavy lifting.)

Any ideas on how to proceed? Do I truly have to install a command line web browser on my server, or worse, a GUI? Also, any suggestions on fine-tuning this .conf file would be appreciated. And before I close with aforementioned horrible .conf file... thank you all for doing this, for helping people use this software so they can realize their dreams/visions/ideas. I think it's amazing. Let me know any other system deets I can provide. <3

server {
    listen 80;
    listen [::]:80;
    root /var/www/bar.example.com;
    index  index.php index.html index.htm;
    server_name  bar.example.com [url=http://www.bar.example.com]www.bar.example.com[/url];

    location / {
    try_files $uri $uri/ @rewriteapp;        
    }

    location /install/ {
     try_files $uri $uri/ @rewrite_installapp;
    }

    location ~ \.php(/|$) {
    fastcgi_split_path_info  ^(.+\.php)(/.+)$;
    fastcgi_index            index.php;
    fastcgi_pass             unix:/var/run/php/php7.2-fpm.sock;
    include                  fastcgi_params;
    fastcgi_param   PATH_INFO       $fastcgi_path_info;
    fastcgi_param   SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_param DOCUMENT_ROOT $realpath_root;
    try_files $uri $uri/ /install/app.php$is_args$args;
    }

     location @rewrite_installapp {
      rewrite ^(.*)$ /install/app.php/$1 last;
     }

}

Offline

#2 2020-06-12 14:56:49

bigtester
New member
Registered: 2020-06-10
Posts: 2

Re: accessing install.php for new install of 1.5.11 on home server (nginx)

Hi all! the fix was absurdly simple: I needed to edit the /etc/hosts of my client computer to redirect bar.example.com to my local IP:

192.168.1.69 bar.example.com

going to mark as solved, thank you for maintaining this forum!!

Offline

Board footer

Powered by FluxBB