Default Installation 3.10.3, but many JS files return 404, why?
-
Hello everyone
This is my environment configuration information:
I am using an AWS EC2 server, with the system being Debian 12, and using the BaoTa Linux panel.The Node.js version is v18.20.5, MongoDB version is v8.0. After installation, the forum address is 127.0.0.1:4567. I am using a reverse proxy to mount my domain aiink.cn.
The installation went smoothly, but upon first run, there were some issues (see the image).
Many JS files cannot be found, and even after searching through the distribution package, I could not locate them, such as the most important ones:
- nodebb.min.js
- admin.min.js
When I compressed the files on the server and downloaded them, I did not find these files either.
I noticed that some file paths were localhost, so I downloaded the config.json from the server and changed the
localhost:4567
in the config.json to127.0.0.1:4567
.After running:
./nodebb stop
./nodebb start
the issue still persisted.
Due to the missing admin.min.js, I am unable to click the 'rebuild-and-restart' button.
Previously, I installed NodeBB v1.6, and there were no such issues.
Is this a configuration problem on my end, or something else?
Feel free to adjust any part of the translation if you need it to better fit your needs or context.
-
@baris said in Default Installation 3.10.3, but many JS files return 404, why?:
nodebb.min.js is generated when you run ./nodebb build in the nodebb folder. Try running it and see if you get any errors. Also make sure you access the forum with the same url used in config.json
As you suggested, I ran the
./nodebb build
, and indeed an error occurred.Could you please advise on how to resolve it?
-
-
@baris said in Default Installation 3.10.3, but many JS files return 404, why?:
I'm not familiar with that error, but you can try a few things.
Don't use root user to run nodebb commands, make sure the nodebb folder is owned by a nonprivileged user. Then run
npm install
with that user and try running./nodebb build
again.ah...I try it
-
@julian said in Default Installation 3.10.3, but many JS files return 404, why?:
@juse please run
npm install
again and try running./nodebb build
again.I'm currently reinstalling everything.
Since I installed
Node.js
,npm
, andyarn
using the root account,
I didn't log out of the root account when installing NodeBB,which resulted in NodeBB being installed in the root folder .
regular users cannot control the root folder
Now, I've deleted NodeBB and am reinstalling it using a regular user account.
-
@baris said in Default Installation 3.10.3, but many JS files return 404, why?:
You are still on the root account.
At first, I also thought it was a permission issue.
So, I deleted all the files and reinstalled them.
This time, I used the default www account.
The command I ran wassudo -u www command
.
But the problem still persists...and I use
npm install
again and./nodebb build
....the problem is still.... -
All issues have been resolved.
What seemed like mysterious problems were, in fact, all related to user permissions.
During the installation environment setup and even when installing NodeBB, use the root account is OK.
However!!!! after that!!!!
I created a regular user named
nodebb
and granted this user permission to thenodebb
directory.Using this user, I successfully ran
./nodebb build
without any issues.I am now using the latest version 3.10.3, and everything is working perfectly without any errors.
-