spritsail / amp-minecraft

Dockerfile for running a Minecraft server through the server management program AMP.
6 stars 2 forks source link

How to update AMP #2

Closed ntimo closed 5 years ago

ntimo commented 5 years ago

Hello, I just pulled the latest image with the Spigot patch, thank you for that. I noticed that the container is still running AMP 1.7.2.4. Now I am asking my self how can I upgrade to 1.7.2.6? So I have to delte the Docker Volume? Which would be kind of not good since all the worlds and data is stored in it.

Thank you in adavance :)

frebib commented 5 years ago

You can try using the update functionality built into ampinstmgr to update the instance, from memory it's something like ampinstmgr updateinstance instance. If that fails then you'll have to backup your worlds & config and create a new instance then copy them back in. Let us know if the update functionality actually works because last I tried it didn't :( Failing that, perhaps you could go and ask for support on the AMP Discord server? :)

frebib commented 5 years ago

I should add that this style of file management that AMP enforces is wrong for containers but unfortunately there is little we can do for a lack of proper versioning of the instances. In an ideal world we would package the specific instance version into a container so you can just pull the container and be updated. Also in an ideal world we'd have the source code so we wouldn't have to do all of this hacky shit around glibc and libraries just to make it run without a million gigabytes of dependencies, but there you go.

ntimo commented 5 years ago

The crazy think is, when I run ampinstmgr --ShowInstancesList then it does not show any instances :( Thats also why I can't upgrade AMP using the instance manager.

frebib commented 5 years ago

This is almost certainly because AMP is storing metadata in a directory that isn't mounted as a volume and was lost when you recreated the container at some point. I'll admit this is one of the reasons I stopped using AMP because it is far too strict about default paths and incredibly inflexible. I suggest you backup the instance you have and copy the files back in to a new fresh instance running the new version. Until then, perhaps there is something we can do with the directory organisation to improve the situation somewhat

ntimo commented 5 years ago

Just out of pure interest, what are you currently using? I thought about using https://multicraft.org/ first, but there are sadly no Docker Containers out there for it :(

Maybe we could backup the metdata inside of the volume and then restore this backup when the container starts before starting AMP?

frebib commented 5 years ago

We're using spritsail/minecraft along with spritsail/mcbackup. We have no use for fancy web-ui pages or anything. I personally find docker restart minecraft easier :stuck_out_tongue:

We've been brainstorming this evening and have some plans to overhaul the way we manage AMP instances so keep your eye out over the next week or two. Hopefully it should allow you to pull-to-update in the future :grin: (with lots of hackery I'm sure)

frebib commented 5 years ago

Also I'd suggest using host bind-mounts instead of docker volumes. Something akin to -v /path/to/persistent/storage:/ampdata .. when starting your container. It's much easier to manage. You'll have to consult the Docker documentation on how to rescue your data from the docker volume :)

frebib commented 5 years ago

Ok I had a small "chat" with the AMP dev and we came to the conclusion that his software makes overzealous assumptions and he can't comprehend that other users may want to package his software in other "non-supported" configurations than the canned blob that they provide. It's very Windows attitude to packaging software and makes my/our lives almost impossible in regards packaging and maintaining the images. For that reason alone I don't think this is going to work/happen, I'm sorry. AMP is great. The design decisions and closed, canned nature of the process is not.