BoxOfSnoo / docker-bedrockserver

The Unlicense
25 stars 15 forks source link

Dockerfile vs startup.sh #3

Open dlamblin opened 5 years ago

dlamblin commented 5 years ago

Half of the setup is in the startup.sh… can't this be done with the Dockerfile to reduce start up time and differences storage?

Additionally the baseimage goes through a whole rig-a-ma-role for handing init, and though you've left it as the command, this command is passed to the entrypoint which is startup.sh and it ignores this argument. Right?

I think it would be better if you'd follow the phusion description of how to add a daemon startup to the system, and leave the command and entry point alone (for that image). Or change the base image and use docker new built in --init and tini and such.

Otherwise, thanks for making a setup that works.

rossknudsen commented 5 years ago

Hey @dlambin

I think the reason that the bedrock server is downloaded on first run is to avoid licensing issues. It's assumed that if/when a user runs the image they are agreeing to Microsoft's licensing terms. Subsequent executions of the container shouldn't require re-downloading as the startup script checks if there server code is present.

I read the doco you're referring to regarding running daemons on base-image and it makes sense to work with the existing architecture. I'll have a look at converting the existing implementation.