Or for a fresh installation:
git clone -b v0.6.x https://github.com/NodeBB/NodeBB.git nodebb
Incomplete Installation - Missing Directories
I just installed NodeBB by following the installation instructions for Ubuntu. As instructed I cloned the git repository. However when I visit the forums, it's obvious that the CSS files are not being loaded. I checked my logs and NodeBB is trying to load the CSS files from a directory called assets, but there is no assets directory. My NodeBB directory looks pretty much like the git repository for the master branch. The plugins directory is also missing.
Are there some steps missing from the installation instructions?
The routes/paths don't necessarily directly map to folders on your disk. Have you configured your site URL correctly? Are you accessing it via the same URL as configured?
Also I hope you didn't only clone the git repository but followed all the other steps in the installation instructions?
@dravere , I can access the site just fine. It's just generating errors due to the missing folders. So yes, I followed all the instructions, including the setup. If the URL wasn't set correctly, I wouldn't be able to access the site at all.
Here are some examples of the errors:
.../nodebb/assets/src/modules/highlight.js" failed (2: No such file or directory)
.../nodebb/assets/stylesheet.css" failed (2: No such file or directory)
.../nodebb/assets/nodebb.min.js" failed (2: No such file or directory)
That is not the complete path. I removed the rest. NodeBB is installed in a directory called nodebb.
I am evaluating new forum software as I look at switching my gaming community, so NodeBB is one of many. I manage my own server. I can access the other test sites just fine, so I think my server configuration is correct.
What is the URL you have configured in your
config.jsonor set during install? Is NodeBB running behind a reverse proxy?
Also just to make sure some other stuff is configured and setup correctly, could you run a
./nodebb buildin the root folder of the NodeBB?
URL is http://test.theassimilationlab.com/nodebb
Yes NodeBB is running behind a reverse proxy.
I just ran a build and here are the results:
2018-06-22T16:48:26.512Z  - info: [build] Building in parallel mode
2018-06-22T16:48:26.514Z  - info: [build] plugin static dirs build started
2018-06-22T16:48:26.517Z  - info: [build] requirejs modules build started
2018-06-22T16:48:26.518Z  - info: [build] client js bundle build started
2018-06-22T16:48:26.522Z  - info: [build] admin js bundle build started
2018-06-22T16:48:26.523Z  - info: [build] client side styles build started
2018-06-22T16:48:26.524Z  - info: [build] admin control panel styles build started
2018-06-22T16:48:26.525Z  - info: [build] templates build started
2018-06-22T16:48:26.526Z  - info: [build] languages build started
2018-06-22T16:48:26.526Z  - info: [build] sounds build started
2018-06-22T16:48:31.625Z  - info: [build] sounds build completed in 5.099sec
2018-06-22T16:48:31.627Z  - info: [build] admin js bundle build completed in 5.105sec
2018-06-22T16:48:31.838Z  - info: [build] plugin static dirs build completed in 5.324sec
2018-06-22T16:48:35.506Z  - info: [build] client js bundle build completed in 8.988sec
2018-06-22T16:48:36.495Z  - info: [build] client side styles build completed in 9.972sec
2018-06-22T16:48:36.496Z  - info: [build] admin control panel styles build completed in 9.972sec
2018-06-22T16:48:36.548Z  - info: [build] requirejs modules build completed in 10.03sec
2018-06-22T16:48:39.306Z  - info: [build] languages build completed in 12.78sec
2018-06-22T16:48:39.310Z  - info: [build] templates build completed in 12.785sec
2018-06-22T16:48:39.311Z  - info: [build] Asset compilation successful. Completed in 12.797sec.
After the build, I'm now getting errors written to the browser, so I am going to shut down the site. You will NOT be able to load that URL. I didn't get any visible errors before I did the build.
The error was regarding a missing directory again.
In regards to the URL I don't need to access it. I only wanted to see that
http://is there and no trailing slashes or other oddities. But it looks good to me.
But I have to say I'm a bit at a loss here. The only possible error I could see is in a misconfiguration in the reverse proxy. Is there anything in the NodeBB log? Or could you start it with
Also just to be sure, you did checkout the branch
Actually when I first attempted to install NodeBB, I was following a slighter older version of the instructions that referred to the 1.8.x branch. I got an error during installation, so I checked and realized the repository had been updated, so I deleted the nodebb directory and started over.
There is definitely something odd going on. Before I did the build, NodeBB was looking for stuff in the assets directory, as I listed above. Now stylesheet.css is in the nodebb/build/public directory. The stuff in the NodeBB logs are the same errors I saw on the screen:
2018-06-22T16:53:14.306Z  - [31merror[39m: /nodebb/categories
Error: EACCES: permission denied, open '/rootdir/appldir/test/nodebb/build/public/templates/categories.js'
Ok, I sorted part of the problem. After doing the build, new directories were created and they were owned by me. I fixed the ownership and now I'm back to busted, but loadable forums now.
If you visit that URL, you'll see what I mean.
I can try ./nodebb dev a bit later.
@andalaybay don't use
sudoto run any
I know. Or to be more accurate, run those commands as the NodeBB user. That's one big omission from the installation instructions: you may need to create the user account if you choose to run NodeBB as the nodebb user. I'm not using "nodebb", I have another account and group that run my web processes and I set nodebb to use them. I created a systemd service to run NodeBB.
Anyway I don't think this is anything in my configuration. I think there's something wrong with the repository. I'll set NodeBB aside and proceed with my evaluations.
I would guess, that your plugins still have the wrong permissions set. Try to run "sudo chown -R nodebb:nodebb <nodebb folder>". Of course replace "nodebb:nodebb" with the user/group you have created in your installation.
I changed the permissions and checked, as I said before. I even tried the alternative configuration from the NodeBB scaling guide. That didn't make any difference. There are missing directories and I don't know why.
I'll delete NodeBB and move on. Thanks for trying to help guys.