-
-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal: Build a single docker container based on Ubuntu 16.04 as our recommend install #624
Comments
i'm in! the only thing i'd add is the experience of another excellent project - Azuracast, which has recommended installation with docker since 2017. |
@Robbt - Probably worth reading my comments here: #552 (comment) This is already in my personal backlog so happy for this one to be assigned to me... In short to support docker properly there needs to be a few "types" of containers:
I'd also be keen to experiment on using something like Alpine Linux over Ubuntu for the minimal build so there's less overhead/try to keep the layers smaller - The Current build with all the Docker Layers is around 1.5GB which is a lot to pull down if you're on ADSL. |
Those are basically just another way to run the same kind of containers... I think flatpak will (or already does) support running OCI containers.
I think some parts of liquidsoap are hard to come by without a glibc (but I haven't tried yet). The new Debian-slim flavor might also be interesting here. Generally speaking I'm not sure why everyone shys to Ubuntu rather than their being more Debian installs as I've found those to be more reliable. My CentOS share a common base layer without much more on top so pulling them is usually ok since you only pull the large base once and everything else is shared. I haven't found the time to write actual helm charts to run and deploy them in a useable fashion... When I last really looked into this I was still waiting for beta things like InitContainers in K8s to become stable for the way they are currently set up to work. If I pursue those containers further I'll going to write helm charts next. To run all of this you'll probably need quite a cluster if you want everything to be HA and fast. Right now audio related container things is more of an R&D thing for me right now. I think it would be interesting to start testing the current icecast beta and aim at writing some kind of K8s operator to manage it at some point. This is the kind of infra that my containers are actually waiting for and so long all the things going on in that space that I've seen have been closed source. |
When the Ubuntu liquidsoap package fix gets into the debian-backport as @paddatrapper is working on that should make building off of Debian feasible. I'm also excited about the idea of providing Debian & Ubuntu packages to install LibreTime as an alternative to docker but I do think a single vanilla docker container would be a good idea. |
#1 Generally, if it works in Debian, it works in the equivalent Ubuntu. Have I missed something? I am often raiding the Debian repos for use with Ubuntu. |
Generally that holds true, however in this case there are slight version mismatches in the various Debian versions that 16.04 happened to get right I definitely do not want to see Docker be the only supported option. While it is simple to setup, it means that anyone using a different containerisation system (LXC for example in my case) cannot use it. Supporting a dedicated host install means that there is flexibility and people with different setups can still use LT. |
? Being the officially supported version does not mean you can't use the GIT, Snap, Flatpack, Marmite or Paddington Marmalade. |
It also means, when an issue is raised - does this happen in Docker? No, closed. Supported isn't just installation, it also includes post install. Also if someone is willing to do the work of creating a deb installation path (i.e. me), then we should think hard before deciding to drop support for that platform. It is the same as the install script. Does only supporting Docker mean that the script falls away? If so, then installing from git is very difficult and is practically a copy-paste exercise that requires you knowing where everything goes and what dependencies are required |
Do you have this working with Minikube for local testing/dev or is it a bit too much - I'd be guessing the overhead is about the same as the Ubuntu docker build? |
@paddatrapper There is no reason why the docker install should not use Debian, Centos, Ubuntu (or Alpine?) in its container. The install script COULD be built into the docker file run script and have a small docker file suck in the rest of the install, like now or a big fat docker image with it already inside. These are dev team choices. Docker is only a container for a pre-configured system. You can easily ssh into the container and administer it, like any other system, and have the /srv/airtime/stor, /etc/airtime/ and postgres data files outside the container. Upgrading LT then becomes a simple job of swapping out the docker container or reinstalling it. All the persistent stuff can stay outside. This has already be done by other LT users, look in DockerHub. or https://github.com/HaJoHe/docker-libretime |
I'd suggest that since we are generally a welcoming community and patient with users that we can "officially" support anything that people are willing to field Q&A regarding. I think recommending docker for people new the project might work especially if we can fully document the entire process to setting up a station (ie inlcuding port forwarding etc). I'm also totally cool with the idea of supporting deb packages as another install path if @paddatrapper wants to put the work in. Since everything is community ran at this point I don't think we need to have a strict interpretation of what we provide help with. But we might want to consider pushing support requests to the forum when they don't represent a bug. |
Just a note. In a plain vanilla host install, ie no apache or nginx on 80 or 443, it should be possible to run it right out of the box with no tweaks at all. |
Yes, but there are other containerization platforms out there. For example - I want to be able to stand a LT instance up using LXC, as this is what my infrastructure is designed around. Thus using the install script on what effectively becomes a bare-metal install (inside the LXC container) works for this use-case. I don't disagree that a Docker container is a good idea and something that we should push to people new to the project, but it should not be the only way we distribute LT. We should rather continue supporting the dedicated host install that we currently have and have Docker for those who just want to run quickly and simply. |
well put. |
hi all HAPPY NEW YEAR!!! ...well almost ;P greetings from the sao paulo, brazil airport. given progress on several fronts, including @hairmare 's recent work towards modern php version compatibility, the new deb package, and all of @Robbt's product and issue queue work, i'm now wondering whether it would make sense to refine this proposal. basically i'd love for our single-container docker install to be as dead-simple as possible. just install the deb using the user's environment vars on a modern linux distro, set up content (db, music files) persistence, and that's it. no cron job, no fqdn fixes, nothing that shoudl rightfully be fixed within the main project feasible? even a good idea? @ned-kelly any update on when you see yourself having time to dig in here? take care folks! all the best for 2019! |
I think that is a very good idea. Then include the build in the release notes for each new version going forward. Between the distro packages, two Docker images and the install script, we've covered most use cases I think. Fixes and improvements should definitely be upstreamed as a first priority |
hello again folks, I'm now thinking of biting the bullet and creating a single-container docker image myself. Not sure what's happened to @ned-kelly, probably work, but given his availability over the course of the last few months I've decided not to wait since I also want to test #670. So let's start the ball rolling: Which distro? for me this choice is mostly about php versions and getting the liquidsoap and silan versions we need, any other major considerations that don't fall into personal preference/familiarity?
thanks everyone! |
Debian Buster is pretty much stable, it goes into transition freeze on 12 Jan and soft freeze on 12 Feb. It shouldn't see much volatility any more (and any that exist will be fixed quickly). Buster should also have the latest version of liquidsoap once I finish packaging the dependencies. Just a note - silan is version 0.4.0-1, not 0.4.0-1+b1. Personally, I would suggest Buster, but that is also because I am pretty biased towards Debian :) |
@Robbt and I discussed this briefly via slack and are also leaning towards Debian 10 given all of Kyle's contributions and the proximity of official release. we weren't sure what specific benefits the latest version of liquidsoap could bring us that do not already come in 1.1.1-7.2ubuntu1, but using the most recent version seems like a good general policy given #192 . php 7.2 v. 7.3 is another somewhat unknown, but choosing 7.3 seems reasonable. @hairmare sound ok? see also https://github.com/LibreTime/libretime/wiki/Distro-Packages#support-matrix |
@paddatrapper the |
@frecuencialibre I'll add support for Buster in the installer as soon as #670 is merged and to the deb once alpha7 is released |
@frecuencialibre - I created #682 to track the installer issue. I would like to get it done before alpha7 |
now wondering based on @hairmare 's comment whether a single container repo is even the best way to achieve simplicity and prioritize fixes to upstream rather than dockerfile acrobatics
how complicated would it be to get postgresql working within a single container? |
I don't think the problem is using PostgresSQL per se but that evidently Docker doesn't have its own systemd running so basically it needs its own custom installation and initialization script. See this stack overflow post. |
Personally I'm thinking that we might want to rethink this proposal considering the realization that docker discourages systemd or a single container with multiple processes. I think that if @paddatrapper is on-hand to continue work on the debian packages than picking Debian 10 and/or Ubuntu 18.04 as our official distributions and providing a single easy to install and upgrade package this might be the preferred route for us to go as the official install. This is contingent on #580 being solved which it seems like #670 is making progress on. I also think that we could also support docker both the multi-container and a single container version and encourage people who want to give it a test run via docker with the single container. |
I've decided that this shouldn't be a blocker for 3-0 beta, it is a good goal but considering we aren't using docker exclusively internally it is probably not a requirement. |
I love the docker idea but I am heavy into docker so a little biased. lol (Personal docker swarm is 72 cores, 512G ram, and 9Tb or Drive space) I have a few projects on Docker Hub that I do the builds for.
That is correct, that docker builds do not use systemd when starting the container. However it does not mean that you can not use it. There are two tricks when building a docker container.
So if you build the container with multiple services you can create an entry script that is
Thus it starts the services and the last one, in this case apache, is started in foreground so it does not exit. As to the Distro discussion, I would pick the one that works best with the software. Docker container users do not make changes in the container because the changes are not persistent without a way to attach persistent storage. (a whole other discussion that I dont see in the thread) so best compatibility is the deciding factor. Persistent storage. My current container (which runs everything in a single container and was not built by me) uses the following persistent storage connections
Which works but has a few issues. The most notable one being that /srv/airtime can not be a single volume mount and has to be two (stor/work) mounts. I've thought about redesigning it as that is not an optimal config and the user should have the option of doing a single mount. There are a lot of other reasons like the way they start stuff and make changes in the entry script that I would do different as well. I think I have rambled enough. Im more than happy to help and answer any questions anyone has on Docker or Docker Swarm. |
So, I've been trying to make a LibreTime instance in Docker and it keeps giving me an error that it can't recognize the OS version, even if the container is running Ubuntu 18.04 or Debian 10. |
See #949 for a working Docker image |
Just want to throw in another idea for the install package: has anyone given thought to making a snap for Snapcraft.io? It says it can auto-build from our Github repo. |
@zklosko it was briefly discussed in libretime/libretime-debian-packaging#3 |
The technical details can be discussed under #551 but this is more for weighing out the pros and cons and making a decision as to whether this theoretical solution would be the best to direct our effort at.
My thoughts in favor of it are the following:
Potential reasons we might want to avoid it:
Feedback and thoughts are welcome.
The text was updated successfully, but these errors were encountered: