Updating Fedora Silverblue with Ansible Playbook
Table of Contents
I really love using Fedora Silverblue, which is an immutable Linux OS.
In the mist of what has happend lately with all the Red Hat drama and Fedora talkings about integrating telemetry into Fedora Workstation, which might also trickle down to the rest of the Fedora family, I still love the OS.
I hope that the Fedora team will pull back on the telemetry suggestion set in motion, but if they choose to go ahead, I might switch to NixOS or Debian 12, with Podman and Distrobox.
To update my Fedora Silverblue, I use an Ansible Playbook to do so. The Playbook will update the OS, as well as Flatpaks and all created Distroboxes:
- hosts: localhost
tasks:
#### RPM-OSTREE ####
- name: Run the upgrade
shell: rpm-ostree update && rpm-ostree upgrade
register: upgrade_output
ignore_errors: true
- name: Display upgrades
debug:
var: upgrade_output.stdout_lines
#### Flatpak ####
- name: Check for flatpak
stat:
path: "/usr/bin/flatpak"
register: fp_service_status
- name: Flatpak update
shell: flatpak update --user -y
register: flatpak_output
ignore_errors: true
- name: Display upgrades
debug:
var: flatpak_output.stdout_lines
#### Distrobox update ####
- name: Check for updates for DistroBox
shell: distrobox upgrade --all
register: db_output
ignore_errors: true
- name: Display updates
debug:
var: db_output.stdout_lines
I hope that someone else might find this Playbook useful and feel free to modify it as you see fit :-)
Read other posts