NodeBB always needs to download & install plugin & themes OOTB on boot
So I'm guessing we all know that NodeBB takes a while to boot, around 2.5 minutes or so to be ready for traffic. I was reviewing the logs and realized that it almost seems like the
Feb 14 22:36:29 => installing plugin (plugin|theme|widget|reward) modules Feb 14 22:36:31 => Could not find plugin firstname.lastname@example.org. Installing it. [...] Feb 14 23:02:14 + email@example.com Feb 14 23:02:14 added 1 package from 1 contributor, removed 3 packages, updated 1 package, moved 13 packages and audited 1771 packages in 6.199s Feb 14 23:02:14 found 1 moderate severity vulnerability Feb 14 23:02:14 run `npm audit fix` to fix them, or `npm audit` for details Feb 14 23:02:14 => Could not find plugin firstname.lastname@example.org. Installing it. [...] Feb 14 23:03:07 + email@example.com Feb 14 23:03:07 updated 1 package and audited 1774 packages in 6.096s Feb 14 23:03:07 found 1 moderate severity vulnerability Feb 14 23:03:07 run `npm audit fix` to fix them, or `npm audit` for details Feb 14 23:03:07 => Could not find plugin firstname.lastname@example.org. Installing it. [...]
It seems to take several seconds for every plugin & theme.
Does it perhaps make sense to include these items in the package itself so that the spin-up time could be considerably faster? Or maybe I'm just misunderstanding how NodeBB works in this case, always possible. haha.
I think those are managed individually via the plugin and theme system. Including them in the package would mean, they cannot get updates between nodebb package updates as well.
Having said that, I don't really know if they in fact ever get updated in-between.
I have noticed this as well when this forum restarts. I have opened a bug to research this - https://git.cloudron.io/cloudron/nodebb-app/-/issues/7 . It should be possible to "optimize" restarts to not install things over and over like we do for Discourse plugins.