Install from CLI with custom plugin-list
-
Hi Community,
this piece of code used to work in a custom setup-script:node app.js \ --setup "{\"admin:username\":\"${ADMIN_USERNAME}\",\"admin:password\":\"${ADMIN_PASSWORD}\",\"admin:password:confirm\":\"${ADMIN_PASSWORD}\",\"admin:email\":\"${ADMIN_EMAIL}\"}" \ --defaultPlugins "[\"nodebb-plugin-custom-homepage\", \"nodebb-plugin-custom-pages\", \"nodebb-plugin-dbsearch\", \"nodebb-plugin-emoji\", \"nodebb-plugin-emoji-android\", \"nodebb-plugin-emoji-extended\", \"nodebb-plugin-emoji-one\", \"nodebb-plugin-markdown\", \"nodebb-plugin-mentions\", \"nodebb-plugin-ns-embed\", \"nodebb-plugin-soundpack-default\", \"nodebb-plugin-spam-be-gone\", \"nodebb-rewards-essentials\", \"nodebb-theme-vanilla\", \"nodebb-widget-essentials\"${modulesToActivate}]" \ || (echo "Unable to install nodebb" && exit 1)
modulesToActivate has a string continuing the array of plugins.
This seems so have changed. It also seem to delete symlinks created in the node_modules folder.
Did anything change?
Or what is the currently recommended way to install from CLI? -
@sebastian-marinescu you should be able to do this with
./nodebb setup
. You just do the following:./nodebb setup [config json] --defaultPlugins="[etc etc]"
As for the npm thing, it's a bug in npm@5, you can try using an older npm version to avoid it.
-
@pitaj Thanks for your answer! The npm@5-symlink-deletion was my main problem, so my command is working again. I would love to see it in the Documentations for future look-ups.
I've anyhow tried using your suggested command with my params
./nodebb setup --params
, but it's not working:- error: unknown option '--setup' - on the first try, then I deleted the setup param
- error: unknown option '--defaultPlugins' - also unknown
I'm on the v1.7.5 branch.
-
@sebastian-marinescu alternatively you could set
defaultPlugins
as an environment variable, then run./nodebb setup [config json]
. I'll re-add an actual option for passing in a set of default plugins. -
@darkpollo the chances of someone responding to a 6 year old thread is going to be almost zero I think. You'd be better off creating a new thread.
-
@phenomlab But that is the beauty of a forum, topics reappear and get back and there is no need to open a new one if this one is exactly the same issue I have now.
@baris
But I need the information about the admin as well and I think that is where the command gets confused (or that is what I think)
I was able to do the setup without the plugins and I think I will settle with that and do the plugins from the admin...
I will try your suggestion just in case.Thanks!
-
@darkpollo said in Install from CLI with custom plugin-list:
But that is the beauty of a forum, topics reappear and get back and there is no need to open a new one if this one is exactly the same issue I have now.
Yes, on the understanding that the original posters are still around. Not always the case so it's best to start a new thread.