DEV Community

Cover image for Run Rancher Desktop on Fedora Atomic Desktops (Toolbox Container Method)
Noor Latif
Noor Latif

Posted on Edited on

Run Rancher Desktop on Fedora Atomic Desktops (Toolbox Container Method)

Complete guide for running Rancher Desktop GUI app on Fedora Atomic (Silverblue/Sway Atomic) using toolbox without rpm-ostree layering that can slow down system upgrades and clutter your system.
Everything is installed into a toolbox container, leaving your main OS free from 3GB+ of rancher desktop clutter.
If you don't have toolbox, you can easily install it using

sudo dnf install toolbox

Step 1: Prepare: GPG Key and Pinentry Setup

Preparation for installing rancher desktop according to official docs, with some quirk fixes for installing inside a toolbox container:

toolbox create rancher
toolbox enter rancher
sudo dnf install -y gnupg2 pinentry-curses pass
echo 'pinentry-program /usr/bin/pinentry-curses' > ~/.gnupg/gpg-agent.conf
gpg-connect-agent reloadagent /bye
pkill gpg-agent
gpg --generate-key  # Enter name and email, take Note key ID output
pass init <YOUR_KEY_ID_HERE>  # Replace with key from gpg output for pub key 
(something like E810C79064F7F543E517F1397DBD5336E1F45F32)
Enter fullscreen mode Exit fullscreen mode

Step 2: Host Sysctl Configuration

Exit toolbox, run on host:

sudo sysctl -w net.ipv4.ip_unprivileged_port_start=80
echo 'net.ipv4.ip_unprivileged_port_start=80' | sudo tee -a /etc/sysctl.conf
sudo sysctl -p
Enter fullscreen mode Exit fullscreen mode

This will enable port 80 usage by non-root apps.

Step 3: Install Rancher Desktop

toolbox enter rancher
sudo dnf config-manager addrepo --from-repofile=https://download.opensuse.org/repositories/isv:/Rancher:/stable/fedora/isv:Rancher:stable.repo
sudo dnf install rancher-desktop -y
Enter fullscreen mode Exit fullscreen mode

Step 4: Launch and Configure

Run this from inside your toolbox:

rancher-desktop
Enter fullscreen mode Exit fullscreen mode
  • GUI launches in your Fedora desktop environment

Step 5: Verify Kubernetes Installation

toolbox enter rancher
kubectl create deployment my-app --image=nginx --replicas=3
kubectl expose deployment my-app --port=80 --type=NodePort
kubectl get svc my-app
Enter fullscreen mode Exit fullscreen mode

Note the NodePort (e.g., 31912), then test:

curl localhost:31912  # Replace 31912 with your NodePort
Enter fullscreen mode Exit fullscreen mode

Visit http://localhost:31912 in your browser to see nginx welcome page!

kubectl get pods
kubectl delete deployment my-app
Enter fullscreen mode Exit fullscreen mode

NodePort access: Rancher Desktop forwards NodePorts to localhost.

Dashboard: Open Rancher Desktop app > Cluster Dashboard button at bottom left.

Optional step: Quickstart Aliases

Add to ~/.bashrc:

alias rd='toolbox enter rancher'
alias rancher='toolbox run -c rancher rancher-desktop'
alias dc='toolbox run -c rancher nerdctl'
alias k='toolbox run -c rancher kubectl'
Enter fullscreen mode Exit fullscreen mode

To activate the changes, don't forget to run source ~/.bashrc

Good luck!

Top comments (0)