node app --setup causes crash
-
I just cloned the github repo. When I try to run node app --setup, after going through all the steps of the setup, this is the error I get:
/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/redis/index.js:535 throw err; ^ ReferenceError: templates is not defined at render (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/src/emailer.js:13:6) at Object.async.parallel.html (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/src/emailer.js:25:4) at /Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/async/lib/async.js:521:25 at /Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/async/lib/async.js:108:13 at Array.forEach (native) at _each (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/async/lib/async.js:32:24) at Object.async.each (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/async/lib/async.js:107:9) at _parallel (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/async/lib/async.js:520:20) at Object.async.parallel (/Users/aaronclaytondunn/Documents/WebDev/forum/nodebb/forum/nodebb/node_modules/asyncAarons-MacBook-Air-2:nodebb aaronclaytondunn$
Any ideas? Thanks!
-
Hi, thanks for the help!
I made those updates and I'm still getting the same error. Here's the requested info:
$ redis-server --version
Redis server v=2.8.4 sha=97ec312c:0 malloc=libc bits=64 build=76d9bf37c9568124$ redis-cli hgetall config
- "title"
- "NodeBB"
- "postDelay"
- "10"
- "minimumPostLength"
- "8"
- "allowGuestPosting"
- "0"
- "allowGuestSearching"
- "0"
- "allowRegistration"
- "1"
- "allowFileUploads"
- "0"
- "maximumFileSize"
- "2048"
- "minimumTitleLength"
- "3"
- "maximumTitleLength"
- "255"
- "minimumUsernameLength"
- "2"
- "maximumUsernameLength"
- "16"
- "minimumPasswordLength"
- "6"
- "imgurClientID"
- ""
- "maximumSignatureLength"
- "255"
- "maximumProfileImageSize"
- "256"
- "chatMessagesToDisplay"
- "50"
- "theme:type"
- "local"
- "theme:id"
- "nodebb-theme-cerulean"
Re redis: I just ran the default server because the config file I have set up that worked with my last build doesn't work locally because of file paths and I figured I'd just test it out with the default redis instance. But I'll try it out pointing to /redis-stable/redis.conf now...
-
Ok that seems to be the issue. You have some users already and when you run setup again it is trying to create a new admin user as uid 5 and trying to send an email which crashes. Not sure why its asking for an admin user though. uid 1 should be the admin. Can you run
hgetall user:1
. That should be the admin user and node app --setup shouldn't ask again. -
Okay, so I got it working by running a config file. But it still has me set up an admin each time. Here's the readout you requested:
$ redis-cli hgetall user:1
- "username"
- "test2"
- "reputation"
- "0"
- "password"
- "xx"
- "gravatarpicture"
- "http://www.gravatar.com/avatar/fb011f4bfe0c3c8d57755071fa4a0463?size=128&default=identicon&rating=pg"
- "uploadedpicture"
- ""
- "banned"
- "0"
- "lastonline"
- "1390440526398"
- "email"
- "[email protected]"
- "lastposttime"
- "0"
- "signature"
- ""
- "uid"
- "1"
- "website"
- ""
- "fullname"
- ""
- "birthday"
- ""
- "picture"
- "http://www.gravatar.com/avatar/fb011f4bfe0c3c8d57755071fa4a0463?size=128&default=identicon&rating=pg"
- "postcount"
- "0"
- "profileviews"
- "0"
- "joindate"
- "1390440376517"
- "location"
- ""
- "showemail"
- "0"
- "userslug"
- "test2"