Lock the screen and set up a greeter

Lock your session

Press Mod+Escape to lock. Swaylock is the stock locker. Tessera keeps the desktop locked if the locker exits unexpectedly and limits automatic restart attempts. Keep a second login terminal available when qualifying a new locker or PAM configuration.

The experimental tessera lock client is opt-in. Before enabling it, have your administrator configure the system's screen-lock PAM stack under the service name tessera and review its policy. It authenticates your real UID. Closing the client, a PAM error, or losing an output leaves the desktop locked. An authentication timeout lets you try again.

(config
  lock: (lock enabled?: #t palette: "orpiment"
          wallpaper: "drift" output: "pointer"))

This configuration only selects the client; it doesn't install PAM policy. When disabled, lock-command: remains authoritative. The built-in background invocation waits for the compositor's lock acknowledgement before built-in before-sleep handling releases its delay inhibitor, with swaylock as a launch fallback.

Choose the lock appearance

Choose a palette and Drift or Facets wallpaper; --wallpaper none disables animation. The field appears on the output under the pointer by default, then falls back to keyboard focus or the first output. Use --output all to mirror it, or a connector name to choose one output. All outputs remain covered. Removing the chosen output moves the field.

Logos must be absolute local PNG paths, at most 8 MiB, 4096 pixels per axis, and four million pixels overall. Coordinates and dimensions use logical pixels. Click a field to focus it, Enter to submit, Backspace to delete one character, and Escape to clear. Caps Lock appears inside the field.

A password accepted with a required password change can unlock, as with swaylock; run passwd afterward. Expired accounts and other account-policy refusals still deny unlocking. Background locking may discard the password change reminder, so follow your system's account-expiration notices.

Recover a failed locker

Switch to another VT and log in as the session user. Identify the exact locker client PID and the locked session's Wayland socket before acting. A live client prevents replacement even when its authentication is stuck. Terminate only that verified client, confirm it exited, then start swaylock on the same XDG_RUNTIME_DIR and WAYLAND_DISPLAY. The compositor keeps the desktop locked during replacement. Don't terminate the compositor unless you intend to close every application in the session.

Use Tessera with greetd

Configure greetd to run tessera greet as its unprivileged greeter account. greetd supplies GREETD_SOCK, performs authentication, and starts the selected user's session. The greeter doesn't load your configuration or start desktop session helpers.

tessera greet --palette orpiment --wallpaper facets
tessera greet --session Tessera=/opt/tessera/bin/desktop-session

Repeat --session NAME=COMMAND to offer more sessions. Explicit commands must be absolute paths; quote a value containing arguments. The option parser groups single/double quotes and backslash escapes, but doesn't expand variables or command substitutions. The authenticated user's environment must make Tessera available, or the session command should use an absolute path.

Tab and Shift+Tab move between username and password. Enter in the username field moves to the password. F2 cycles sessions. F11 restarts and F12 shuts down, each requiring confirmation after the confirmation has been visible for at least half a second. Escape cancels a conversation. Returning to the username preserves it and clears the password.

On Guix, use greetd-service-type with a terminal whose default session user is greeter and whose greetd-user-session runs Tessera with the greet argument. On NixOS, enable services.greetd and set settings.default_session to the greeter user and absolute Tessera greet command. The locker uses a separate PAM service. Keep a spare VT and qualify VT switching on your actual seat before making this your only login route.

greetd 0.10.3 rejects a password requiring a change at login; change it at a text console first. A greeter-to-session transition can briefly show a black console while graphics starts. Logo handoff options can match boot artwork, but physical takeover depends on your loader, display mode, and driver.