My question is 2 fold......I recently downloaded and installed the Google Analytics plugin provided through NodeBB, and once I did, something odd happened to my forum where myself and my other admin are unable to access the admin options without first clearing all cache and cookies. If I'm in the admin, I can't get back to the homepage, and vis versa. I don't know for sure if it was caused by the plugin download, but it all happened at the same time.
1 - Has anyone had this problem with cache, cookies, and admin access? I have tried multiple browsers and uninstalling the plugin, no fix yet.
2 - Is the plugin responsible? If not, how do I get that to work?
Locked myself out of admin
is there a way to rebuild the database to its inital state?
I played around with the admin tools and made myself a normal user by accident. Now I cant get into admin, which is pretty disastrous as I'm the only user.
We really should not let users remove themselves as admin... Good suggestion.
If you'd like to re-add yourself as admin, type this into your console.
$ redis-cli sadd administrators [uid]
... where [uid] is probably 1.
To simply reset the database, type in:
$ redis-cli flushall
As you can tell, it's pretty easy to flush an entire database. All the more reason to make sure your server is secured!
flushallwill empty the redis database, which is the default state of NodeBB. When you run the setup script again, it will repopulate the database with the default info.
This post is deleted!
Thanks a bunch, @julian !
This should probably be added to the Documentation for users who don't know much about redis.
You're right, it should.
I'll add it to the FAQ when I get a free minute.
Note: The next version of NodeBB won't allow you to remove yourself as admin