L
o
a
d
i
n
g
.
.
.
https://michele.zonca.org

linux

A minimal Wayland session for Ghostty, without GNOME Shell

By Michele Zonca

#linux

#wayland

#ghostty

#terminal

15 September 2026

3 minutes to read

September 15, 2026

Most of what I do on my laptop happens inside a terminal: Ghostty, tmux, vim, Claude Code, Codex. GNOME Shell, the dock, the extensions, the wallpaper and the notification stack are all still running underneath, even when none of them are doing anything for me. I wanted to see how much of that I could strip away on battery, without losing my normal desktop session for everything else, so the plan is a second login option: a “Ghostty Minimal” session with no GNOME Shell, no Mutter, no dock, no extensions.

The first constraint is that Ghostty cannot run directly on a raw TTY. On Linux it is a GTK4 application, so it needs a Wayland or X11 compositor underneath it regardless. Stripping GNOME Shell does not mean stripping the compositor entirely, it means replacing it with the smallest one that will do the job. Cage fits: it is a Wayland compositor built specifically to run a single application, maximized, kiosk-style.

On Ubuntu/Debian the package is already there:

sudo apt install cage

Then a wrapper script:

sudo vim /usr/local/bin/ghostty-session
#!/bin/sh

export XDG_SESSION_TYPE=wayland
export XDG_CURRENT_DESKTOP=ghostty

exec cage -s -- ghostty
sudo chmod +x /usr/local/bin/ghostty-session

And a session file in the directory display managers scan for Wayland sessions:

sudo vim /usr/share/wayland-sessions/ghostty-minimal.desktop
[Desktop Entry]
Name=Ghostty Minimal
Comment=Minimal Wayland session with Ghostty
Exec=/usr/local/bin/ghostty-session
Type=Application
DesktopNames=Ghostty

After logging out, GDM offers a second option next to the regular Ubuntu/GNOME session: “Ghostty Minimal”. Picking it, the process tree is just GDM, Cage, Ghostty, and the shell inside it, none of gnome-shell, mutter, the panel, the dock, extensions, animations or the overview. Closing Ghostty kills Cage and drops back to the login screen.

The part I actually care about is running it with tmux attached from the start:

exec cage -s -- ghostty -e tmux new -A -s main

That turns the whole session into one persistent tmux window: shell, an ssh connection to another machine, Codex, Claude Code, lazygit, btop, all in one place, with nothing else competing for CPU or memory in the background.

There is an even more minimal way to try this, without touching GDM at all. From a raw TTY (Ctrl+Alt+F3), after logging in:

dbus-run-session cage -s -- ghostty

Cage’s -s flag lets it manage the VT switch itself, so this works without a display manager in the loop. It is a good first test before setting up the GDM session files.. but I did it and now I can log in with a minimal terminal interface with the power of Ghostty!