PassiveLemon / tmodloader1.4-docker

Docker container for a tModLoader 1.4 dedicated server
GNU General Public License v3.0
10 stars 3 forks source link

Interacting with Server #10

Closed Kennochas closed 2 years ago

Kennochas commented 2 years ago

Is there any way to interact with the server when its running? For instance, if I wanted to to save the server, as it does not seem to save when exiting the container.

Kennochas commented 2 years ago

adding --interactive appears to have let me do a docker attach Terraria, and then interact with the console.

PassiveLemon commented 2 years ago

If you run the docker with -i (in your case, --interactive. same thing), then yes, you can attach and run commands.

PassiveLemon commented 2 years ago

If I wanted to to save the server, as it does not seem to save when exiting the container.

By the way, I do plan on somehow adding a feature that saves the server when shutting down the container but I'm not quite sure how that would work and still be able to interact and view the server logs from the docker desktop client.

Kennochas commented 2 years ago

I had found this container that does it but the rest.

Maybe it will provide inspiration?

https://hub.docker.com/r/rfvgyhn/tmodloader

PassiveLemon commented 2 years ago

That's a very interesting way to do that. I'll look into that more. I'll see if I can get that working by the next release

Kennochas commented 2 years ago

https://github.com/rfvgyhn/tmodloader-docker

Thats the github if you didn't see it as well.

Good luck sir!