Does distrobox have automatic updates setup?

I was just wondering if containers created through distrobox (specifically with the just commands if that matters) have automatic updating setup like the flatpaks and OS? Thanks :slight_smile:

Let’s walk through it! The just update command does a few things:

update:
    #!/usr/bin/env bash
    if systemctl is-enabled ublue-update.timer | grep -q enabled;
    then
      echo "Starting the ublue-update service"
      sudo systemctl start ublue-update.service
    else
      rpm-ostree update
      flatpak update -y
      distrobox upgrade -a
    fi

If ublue-update is on the system it’s does it’s own thing. We use this in bazzite and bluefin for a few reasons I’ll get to later on, let’s go through the others first. If you’re on any other image we do an rpm-ostree update, flatpak update -y, and distrobox upgrade -a. This covers the system, the GUI apps, and then your CLI apps in three steps.

In your case if you look at distrobox upgrade -a that will go through each of your distroboxes, and do an upgrade for each one. That means that if you keep adding distroboxes it’ll keep them all updated.

If you are on bazzite or bluefin we use ublue-update. This adds some logic that people wanted like the ability to only update when the battery is at a certain level, and can be configured to take cpu and memory load into account.

It’s silly that we have multiple ways to update but ublue-update handles edge cases like the steam deck progress bar and we still don’t have a way to install to a directly signed image. It plays a crucial role in ensuring that the first-install update rebases people to signed images. Hope this info helps!

Reference:

3 Likes

Thank you Jorge, that’s a really helpful. But I think I worded my original post incorrectly - I meant scheduled updates rather than automatic. I know that ublue has scheduled updates for the system and flatpaks but I don’t know if it covers distrobox. Apologies if it’s a basic question but I’m not sure how to check.

However I’m guessing now that it’s the just update command you just explained that is scheduled, which would mean that distrobox containers should be included as well in the scheduled updates, correct?

EDIT: Ignore the above, I just realised that the conclusion I came to is probably what you meant when replying :laughing: Thanks!

1 Like