Page 1 of 2
Unofficial CumulusMX Docker Image
Posted: Tue 15 Nov 2022 1:06 pm
by Nossie
Ok
So latest Armv8/Arm64 build should be working as 3.22.3 (build: 3214)
basic docker compose file attached - remove the txt extension to use (notice phpMyAdmin is arch specific, this needs changed)
Dockerfile attached - remove txt extension to use
build.sh attached, remove txt extension -- this is what I've been running after dropping multi arch - multiarch was only ever proof of concept, so apologies if you had been using this.
multiarch.sh attached - also remove txt to use
Once we finalize something I'll just zip anything up that's needed, but ideally for most people they should just need the compose file.
So I've never really messed with docker builds before, so this was more educational for me than anything else. Below is the multi arch guide, however I could only almost get it working with the 'hard' way and again I stopped looking into it further and did no testing on the other archs.
https://www.docker.com/blog/multi-arch- ... imple-way/
Re: Unofficial CumulusMX Docker Image
Posted: Tue 15 Nov 2022 7:34 pm
by hucknz
Cool, I see what you're up to. Have you made many changes to the MXWeather.sh file?
In terms of the build process, I solved this using Github Actions. Not sure if you're familiar, or have access, but it's pretty cool. There are two scripts:
Check for release
This runs daily on a cron schedule and checks the build number on the cumulus repo against a text file in my repo. When it detects a difference it writes the new build number to the text file.
Build and push
This script watches the folder containing the text file in my repo and triggers any time it's updated. The build then creates whatever platforms are specified in the build arguments. When the builds are pushed they're tagged with the build number and latest, the idea being that there's then a history of images so if you want to roll back you can just specify a version tag.
If you want to take a look at how it works my repo is here:
https://github.com/hucknz/cumulusmx
The build stuff is under the .github/workflows folder.
Re: Unofficial CumulusMX Docker Image
Posted: Wed 16 Nov 2022 2:17 am
by Nossie
I haven't made any changes to mxweather.sh
I really like those github actions, I'm not familiar with them at all, however what you have done seems much more useful than the guides I was trying to follow previously!
Can I ask, have you ever had any permission errors with yours?
Re: Unofficial CumulusMX Docker Image
Posted: Wed 16 Nov 2022 2:22 am
by hucknz
Thanks. I had fun learning how to use it and liberally borrowed ideas from others. The main benefit for me is the automation, I can just leave it there running in the background.
When you say permission errors do you mean with the build or in the container itself?
Re: Unofficial CumulusMX Docker Image
Posted: Fri 18 Nov 2022 8:17 am
by Nossie
Sorry,
My aim originally was that someone could just copy paste the docker compose details and install cumulus with just that information. However regardless of how I tried, the host would always create the initial container as root.
Have you had that experience or were you able to create it as a non root user?
Do you think we could maybe clone your information into a dedicated cumulus account (for docker hub and github) and hand the keys to an admin so that even if both of us disappear the project could still continue by someone that picks up the mantle?
Re: Unofficial CumulusMX Docker Image
Posted: Fri 18 Nov 2022 9:15 am
by HansR
@admin: would it be interesting to make a separate docker forum somewhere (e.g. in the general/other block)? This does not seem to be a CMX issue and also does not seem to fit anywhere else. But maybe it does fit somewhere in an existing place

Re: Unofficial CumulusMX Docker Image
Posted: Fri 18 Nov 2022 9:18 pm
by Nossie
I would like to suggest a home automation section - which would contain
Docker/docker compose
home assistant
homebridge
MQTT
node red?
influxDB
possibly more?
That sort of thing, I realise that docker does not fit directly with home automation, however home automation does certainly fit with lots of docker. I do believe most of the above goes hand in hand.
As an example, even though it has taken me 4 months to get there after going down Hans fantastic Cutils path - all I ever wanted was to run CMX, export it to influxDB and then use it within my home assistant setup (btw without you Hans, I couldn't have had cool public graphs and a fantastic site to share with my town, so I would never ask for those 4 months back)- but this is not just my personal request, I genuinely feel there are many people out there that would be looking for something similar, just my two cents.

Re: Unofficial CumulusMX Docker Image
Posted: Sun 20 Nov 2022 5:37 pm
by Nossie
Arm64 arch updated to Patch release 3.22.4 - build 3215.
Re: Unofficial CumulusMX Docker Image
Posted: Sun 20 Nov 2022 7:30 pm
by hucknz
My aim originally was that someone could just copy paste the docker compose details and install cumulus with just that information. However regardless of how I tried, the host would always create the initial container as root.
I think this might be one of the downsides of docker, it runs as root. I believe there's an alternative called Podman that is effectively a non-root user but I don't have any experience with it.
With the container being created as root, how does that cause problems?
Do you think we could maybe clone your information into a dedicated cumulus account (for docker hub and github) and hand the keys to an admin so that even if both of us disappear the project could still continue by someone that picks up the mantle?
Happy to contribute to that. I did suggest in my initial comment (on the original thread) that if the Cumulus MX team were interested I'd be happy to contribute to an "official" docker build pipeline under their repo so all of the things can live on if one or both of us has to drop out. Still more than happy to support that effort.
Arm64 arch updated to Patch release 3.22.4 - build 3215.
Cool! I saw there was a new release today, here's hoping the automated process picks that up later today (runs around 7-8pm UTC) and builds as expected.
Re: Unofficial CumulusMX Docker Image
Posted: Sun 20 Nov 2022 9:29 pm
by hucknz
Looks like the build ran as expected, b3215 is up on docker hub.
Re: Unofficial CumulusMX Docker Image
Posted: Thu 01 Dec 2022 11:31 am
by Nossie
hucknz
sorry I'm going to get back into this in the next few days - do you know if usb support works within your environment?
Re: Unofficial CumulusMX Docker Image
Posted: Sat 10 Dec 2022 7:56 am
by hucknz
No worries. By usb support you mean being able to connect the display for the station via usb to sync data? If that’s the case then yes. I’m using it with a Fine Offset clone.
Re: Unofficial CumulusMX Docker Image
Posted: Sat 10 Dec 2022 4:11 pm
by Nossie
the base image that we used had a build for usb and one without usb - I believe with his image it wouldn't boot or would error out if you didn't have usb connected.
Do you know if your image boots without USB? or would it work if you commented it out of the docker-compose file?
I'll be honest, I don't think the creators are interested in setting up an official docker repository - but I'd rather get it off our own personal accounts so that if either of us disappears it can still be maintained. We should setup a separate github for the releases, you and I have admin and keep an admin login that we can give to Freddie or one of the other board admins for the future.
Re: Unofficial CumulusMX Docker Image
Posted: Sun 11 Dec 2022 6:18 am
by hucknz
I don’t think there’s any issue running it without the usb pass through, I think that’s how I got it set up originally, but I can try testing it and confirm.
Happy to setup a new repo if that’s easiest. Have you asked the admins if they’d be open to creating one within the main cumulus repo? At least if we ask we get a clear answer either way.
Re: Unofficial CumulusMX Docker Image
Posted: Wed 14 Dec 2022 10:14 pm
by hucknz
I can confirm the container starts fine without the USB passthrough.