Configure session-sharing plugin with JSON file instead of UI for docker
-
Hello,
We are trying to use the nodebb-plugin-session-sharing plugin for our existing web app but, because we can't access the admin account (password is long lost and we don't actually have access to the mongoDB either), we need to be able to launch it though a docker image with the config options already in place. We've tried hard-coding them into the library.js file but that hasn't worked. It seems like the custom plugin is getting overwritten or not making it to the deployment in the first place. Any additional logs we add to the library.js file also do not appear.
I see there is one other user who has opened an issue for this on GitHub (https://github.com/julianlam/nodebb-plugin-session-sharing/issues/135) but they haven't received a reply. Does anyone have any suggestions how this can be accomplished?
Thank you! -
How do you not have access to mongodb? If you can connect to it from NodeBB, you can connect to it from a cli.
-
@pitaj Docker
@CassC I would probably just introduce a new custom upgrade script that resets the admin password. You can see how passwords are set during user creation:
async function storePassword(uid, password) { if (!password) { return; } const hash = await User.hashPassword(password); await Promise.all([ User.setUserFields(uid, { password: hash, 'password:shaWrapped': 1, }), User.reset.updateExpiry(uid), ]); }
-