Changing from headless to sway spin

I have a headless desktop installation which I want to change to have a sway desktop.
What is the best path for the change?

sudo dnf install sway
sudo dnf install sway-config-fedora
1 Like

It’s been a long time since I did this, so I’m not going to claim it as the “best” path. I checked the command syntax against the steps I think I followed, but that’s the limit of testing I’ve done.

If you’re already running headless then I’m assuming you’re happy on the command line if you end up needing to troubleshoot or fiddle with extra settings.

I would use dnf to install the relevant package groups, which should get you most of the way there:
dnf group install swaywm swaywm-extended
You could pick a smaller set of packages, but those two should cover the basics.

I think you would then need to enable sddm as your display manager/login screen and make sure the system is set to boot into graphical mode by default, as I don’t think dnf would set that up for you:
systemctl enable sddm.service
systemctl set-default graphical.target

Reboot and you should end up looking at the SDDM username and password prompt, with sway selected (or available to select) as the session type. If not then I’d switch to a different VT with CTRL+ALT+F3 and take a look at the journal entries for that boot (journalctl -b) and start troubleshooting.

1 Like

Perfect!
Thanks.
One small additional step - I had to first remove the existing gdm:
systemctl disable gdm.service

1 Like

I fixed your typo, as it said disable gdm with systemctl disable sddm.service

2 Likes

Thank you (:hat_down)

There is a section on login managers on the Sway website. sddm is not mentioned, but if it works, great. The wiki there is definately wirth the read.

https://github.com/swaywm/sway/wiki/Useful-add-ons-for-sway#login-managers

It’s the display manager used by the Fedora Sway Spin, although not specifically mentioned on the landing page.

+1 for that wiki page as a resource as well - I’ve made plenty of use of it.

Sway’s customisable enough that we could probably have a long list of people’s specific tweaks and configurations. I know I keep meaning to document mine.