Update Plugins on Bungeecord Network Servers

I’ve had a look in the forums but could not find any similar threads.

I have a bungee network with around 8 servers many of which share the same plugins. Its quite tedious to manually update all plugins to each server when there is an update to a plugin.

Is there an easier way to update the same plugins on all the servers in one go?

Thanks for your help and ideas on how to achieve this.

look into how to make symlinks in linux, but basically you want to make a central directory for all your plugins and then symlink that where you need to.

although not sure about how viable this is because i have never done it in this sort of context but it should work in theory.

or you could write a command script that downloads all the plugins you need and then duplicates them into each server plugin folder, but if the symlinks work its probably a better and easier method tbh.

Appreciate the input Ank. However would it cause any issues with all the servers sharing 1 jar file per plugin?

Also what’s the best way to create symlinks via Putty or something, or is there anyway I can create in windows and then transfer across?

Yeah i agree it sounds like it would be a bad idea to me too because its jar files that will be run and then trying to use those over several worlds hence why i said not sure if its viable because i have never actually done this sort of thing with Minecraft before. Although the Minecraft jvm probably just takes those jars in at runtime i am not sure to be honest but one way to find out is use a test world and try to delete a plugin while the server is running, if it deletes the plugin then this is telling you that symlinks will work.

Looking on goggle though it seems to be a thing that people have done idk i guess just try it and see. Otherwise you will have to write a bash script that downloads the files and renames them to a generic name and then can distribute those files by duplicating them to each plugin directory.

They would need to be renamed in the script because most plugins have version information in them like mcPluginV0.1234 etc would just become mcPlugin that way when you need to download new versions it works as intended.

yeah you need to make them on the Linux machine itself well there is no reason not i mean you could essentially make them on another computer but there is no point doing that.

Pretty sure anything Windows created like that won’t translate to linux. Multiple access to the plugin jar would be my concern also, unless it’s loaded into memory and you just boot the servers one after the other.
A bash script wouldn’t be too difficult to write I imagine, have a specific directory you download into, script strips the version info from all files and copies to each directory.
That said, using winscp to copy the plugin to each server isn’t too difficult either. The most onerous task is shutting down all the servers in my opinion.

I think symlinks adhere to posix standard which means unix compat. I am not certain but they should work on all systems in context that you could in theoy makes some on a windows machine and then transfer those over to a linux one never tried it but i think its possible.

i just tried it out of curiosity now lol but yeah symlinks will work because i was able to delete the plugin while the server was live.

further if you wanted on demand sort of updating then the concept would be make a central directory and curl your files into it where you would need to check for dates and versions using curl commands combined with bash script.

which can be found on the curl man page

or maybe wget but i think wget has less commands i am not sure if it can check dates etc.

you can then symlink that directory across your servers

I’m not sure what this is proving.

Because the plugin file can be deleted when the server is live means that it will be safe to symlink those plugin jar, if the result were different like the file is locked in memory and cannot be deleted because its actively being read/write then that would be a different story and would not be a good idea to symlink.

unless i am wrong but it seems logical to me

i don’t really know java but isn’t a jar file just a container that stores classes?
The jvm must take in those plugin jar or inherent those external classes and put them into the jvm at runtime meaning they are useless after they are loaded into the jvm again idk the exact process but i am sure its something along these lines given the simple fact i could delete the file.

i never showed it on the video after deleting the plugin but i was still able to do commands for that plugin and it was still on the server and functional after the fact.

Hi again Ank, I just want to say thanks for your suggestion. I have been doing this with symlinks as you suggested for a while now.

It works exactly as intended and now I just have to update the plugins once from a central location.

Makes my life much easier not having to update 8+ different servers with the same plugins.

Of course I also take the version numbers off the filenames so they all link to a common name such as ViaVersion.jar rather than ViaVersion-4.4.2.jar

Thanks again!