Trying to make sunshine work in Bluefin

Hi. I’m trying to install and use sunshine as it works in Bazzite, so far no success, I layered sunshine but I get the “Fatal: You must run [sudo setcap cap_sys_admin+p $(readlink -f $(which sunshine))] for KMS display capture to work! If you installed from AppImage or Flatpak, please refer to the official documentation: Sunshine: Getting Started” error, and when I try to run that in the terminal I get “Failed to set capabilities on file ‘setcap’: Read-only file system”

How can I install it like it is installed in Bazzite?

After a couple of days with no response I managed to make it work

:white_check_mark: Native Installation of Sunshine on Fedora Silverblue (Bluefin) with setcap Support

This guide will walk you through installing Sunshine natively (outside of Flatpak or Toolbox) on Fedora Silverblue or Bluefin, and enabling advanced features like virtual displays by setting Linux capabilities.


:small_blue_diamond: Step 1: Remove Old or Conflicting Versions

To avoid conflicts, remove any older versions of Sunshine (Flatpak, AppImage, Toolbox, etc.).

:soap: Remove Flatpak (if installed)

flatpak uninstall --delete-data com.lizardbyte.sunshine
flatpak uninstall com.lizardbyte.sunshine

:soap: Delete AppImage (if used)

rm ~/Downloads/sunshine*.AppImage

:soap: Exit Toolbox (if you’re in one)

exit

:small_blue_diamond: Step 2: Install Sunshine via Copr RPM on the Host System

Since sunshine is not available in Fedora’s default repos, install it from the Copr repository.

:inbox_tray: Example for Fedora 40:

sudo dnf copr enable lizardbyte/beta
sudo rpm-ostree install Sunshine

### 🔁 Reboot to apply:
systemctl reboot

:small_blue_diamond: Step 3: Verify the Correct Binary Is Installed

After rebooting, confirm the correct version of Sunshine is installed and accessible:

which sunshine
readlink -f $(which sunshine)
sunshine --version

Expected output:

/usr/bin/sunshine

:small_blue_diamond: Step 4: Grant Required Linux Capability

Grant cap_sys_admin so Sunshine can create virtual displays and manage low-level features:

sudo setcap cap_sys_admin+p /usr/bin/sunshine

:white_check_mark: Confirm it was set:

getcap /usr/bin/sunshine

Expected output:

/usr/bin/sunshine = cap_sys_admin+p

:small_blue_diamond: Step 5: Run Sunshine

You can now launch Sunshine:

sunshine

Or optionally configure it as a systemd service for background operation.


:white_check_mark: Run Sunshine as a User Systemd Service (Wayland + Audio)

Running Sunshine as a user systemd service allows it to launch automatically with your session and access your Wayland display and audio (PipeWire).


:small_blue_diamond: 1. Create a Systemd User Service File

Run:

systemctl --user edit sunshine.service

Paste the following into the editor:

[Unit]
Description=Sunshine Game Streaming Server
After=graphical-session.target pipewire.service
Requires=graphical-session.target

[Service]
ExecStart=/usr/bin/sunshine
Restart=on-failure
Environment=PATH=/usr/bin:/usr/local/bin
Environment=XDG_RUNTIME_DIR=%t
Environment=WAYLAND_DISPLAY=wayland-0
Environment=DISPLAY=:0
Environment=PULSE_SERVER=unix:%t/pulse/native

[Install]
WantedBy=default.target

Save and exit the editor.


:small_blue_diamond: 2. Enable and Start the Service

Enable the service to start at login:

systemctl --user enable sunshine.service

Start it immediately:

systemctl --user start sunshine.service

:small_blue_diamond: 3. Check the Service Status

systemctl --user status sunshine.service

You should see active (running) if everything is working correctly.


:memo: Notes

  • %t expands to your runtime directory (e.g. /run/user/1000), giving access to your Wayland session and PipeWire audio.
  • PULSE_SERVER ensures Sunshine can connect to PipeWire’s PulseAudio server.
  • Works seamlessly in Silverblue and Bluefin with PipeWire-based systems.
1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.