scrotwmos
SWMTOOL-ANSWER(5) File Formats Manual SWMTOOL-ANSWER(5)

swmtool-answer — scrotwmos install plan

An answer file, or plan, tells swmtool(8) what to install. swmtool plan writes one from the install questions, and swmtool install reads one.

The format is that of scrotwmos.conf(5): one key = value per line, an optional [name] after the key, and ‘#’ for a comment, at the start of a line or after a value: a value has no ‘#’ in it. Only ‘=’ is allowed. Each key appears once. An unknown key is refused. There is no password key. Passwords come from the terminal or from --passwords when the plan is installed. A password key is refused by name.

A plan installs one of two things, by base: dom0, the appliance with its worlds, or byol, a plain Void Linux with scrotwmos as its window manager.

(the default) or byol.
The keyboard layout, one the install stick carries, compiled in its release's keymaps/: us, gb, de, fr, es, it, nl, pt, se, no, dk, fi, be, ch or br. Required. Passwords are typed in it, at the boot too. A password with a character that needs AltGr is refused: the boot may not read AltGr. At the boot, type a password's digits on the main row, not the keypad: where the digits need Shift (fr, be) the keypad types other characters there. Over a serial console, the boot reads the keys as US for a layout other than US: type the keys a US keyboard has for the password.
The disk to erase: /dev/disk, a whole disk by its serial as /dev/disk/by-id/name, or largest, largest-nvme, or only, which never pick a removable disk. only refuses a box with none or more than one. Required.
or no: whether a disk that holds data is erased, as --force does. The default is no: such a disk is refused, and nothing is written.
or no: whether the install stick installs this plan with no question, when the plan is on the stick as swm/plan. The default is no: the stick shows the disk and asks for its name first. swmtool itself asks nothing only under --batch.
Letters, digits, dots, and hyphens, 63 at most; the first is a letter or a digit. The default is scrotwmos.
A zone under /usr/share/zoneinfo. Required. For dom0, it is UTC.
Where the packages and the firmware come from: an http or https URL, or an absolute path. The default is the Void mirror, https://repo-fastly.voidlinux.org/current.
The swap partition: auto (the default, the machine's memory plus 10 percent, rounded up to a GiB, 1 GiB at least), none, or a size of 1 to 6 digits and M or G, 256M at least. A disk with no room for it beside the ESP and swmdata (a dom0's) or the root, 4 GiB at least (a byol's), is refused: answer a smaller swap. The swap gets a new key at each boot, a byol's and a dom0's alike.
(the default) to overwrite the swap partition with random data, or no.
(the default) or static. A plan with static is parsed, but swmtool install refuses it before anything is written.
With network = static only, and then required: the address and its prefix length, a.b.c.d/n, n from 8 to 30, the address a unicast host on its subnet, neither the network nor the broadcast address.
With network = static only, and then required: another host on address's subnet.
With network = static only, and then required: one to three name servers, separated by commas.

These keys are for dom0.

or no (the default): whether the appliance takes input devices plugged in after boot. A byol plan with it is refused: byol's is its own OS's policy.
(the default) or no: whether the root monitor takes a point of a world's home each hour, read back with swmtool points and open --point. Points share the disk with the worlds, so the disk fills sooner. A world added later with swmtool world takes the same. A byol plan with it is refused.
A USB disk, erased and made the backup place of each A/B world that is a container, as F11's p makes one: /dev/disk/by-id/name only, never /dev/sdX, whose name moves between boots. The install makes it one XFS file system with a directory for each world, by the world's name. The first boot then copies the home there with no question. A disk plugged in after boot waits for F7's accept, as any USB device. Refused when it is the install disk or the install stick, when it is not on USB (the root monitor finds a place on USB alone), not a whole disk or in use, when no A/B world is a container, and for a byol, which has no backup place. A disk that holds data is erased only with erase or --force, as the install disk. None is the default: no disk is touched, and F11 makes the place later.
[address]
A network card the release has not measured, allowed at install, a dom0's: address as sysfs names it (0000:59:00.0), the value its vendor, device, subsystem vendor, and subsystem device, four hex digits each, lowercase (8086:15f3:8086:0000). The install seals each world's approval of it as F5 does. The approval is bound to the card's ids, address, and IOMMU group, to the box's identity, and to the net VM's kernel. The first boot then gives the card to the net VM with no measure. Refused when the card is not at that address with those ids, its release row is not none or deferred, its IOMMU group holds another device but a port, or the box has no identity. Refused for a byol. At most 16, one for each address.
[address]
An option ROM approved at install, a dom0's: the value the ROM's sha256 as the first boot's probe reads it, 64 lowercase hex digits. The install seals each world's record of it as F9's approval does. Refused when the device at address has no ROM, or another, or is one the wizard does not ask of: its release row not allowed and no nic_allow for it. Refused for a byol. At most 16, one for each address. Each world's record says “approved at install”, as F9 lists it.

A plan for dom0 names one or more worlds. Each world's keys take its name as the selector. There must be at least one A/B world, at most one rescue and one decoy world, and at most eight usernames in all, none used twice.

[w]
The kind of world w: ab, rescue, or decoy. A name starts with a lowercase letter and holds lowercase letters, digits, and hyphens, 16 at most, and is not host or share.
[w]
The usernames that boot the world, separated by commas: two for ab, slot A first, and one for the others. A username starts with a lowercase letter and holds lowercase letters, digits, underscores, and hyphens, 32 at most, and is not root or nobody.
[w]
(the default) or vm. A decoy is always a VM, and a rescue world always a container.
[w]
What the world's session reaches: guest (the default), the internet only; lan, the LAN only; full, both; or none. On a dom0 with no network, none only. Not on a rescue world, which uses the host's network, nor on a decoy, which is always guest.
[w]
The session's LANG: C.UTF-8, en_US.UTF-8, or a keyboard layout's locale: en_GB.UTF-8, de_DE.UTF-8, fr_FR.UTF-8, es_ES.UTF-8, it_IT.UTF-8, nl_NL.UTF-8, pt_PT.UTF-8, sv_SE.UTF-8, nb_NO.UTF-8, da_DK.UTF-8, fi_FI.UTF-8, fr_BE.UTF-8, de_CH.UTF-8, or pt_BR.UTF-8. For a container; not on a rescue world. When it is not given, the keyboard's first layout's: us gives C.UTF-8, gb en_GB.UTF-8, be fr_BE.UTF-8, and so on; any other layout C.UTF-8. The wizard asks for the keyboard alone and writes no world_lang.
[w]
The most processes and threads the world's session may run: 4096, 8192 (the default), or 16384. For a container; not on a rescue world.
[w]
Package sets, separated by commas, each once: shell, firefox, chromium, c-development, go-development, office, nvidia, and rescue. nvidia is what a VM given a whole NVIDIA GPU needs. The wizard adds it to the VM that takes one. The default is shell, and shell,rescue for a rescue world, which must keep rescue.
[w]
More packages by name, separated by commas, 32 at most.
[w]
As world_session_gpu, for an A/B world's own session when it is a VM.
[w]
or no: whether the world's default session (named after the world) is in the world's share, a directory at /share on an image under the world's key alone. The default is no. The world gets its share only if one of its sessions is in it, and a session not in it has no route to it. Rescue and decoy worlds take no.

An A/B world can have up to four sessions besides its own. Each session's keys take its name as the selector. The name follows the world name's rule and is not a world's name.

[s]
The A/B world the session belongs to.
[s]
The session's workspaces, from 1 to 10, as a range such as 4-6 or a list such as 4,6. Required. No two sessions share a workspace, and the world keeps at least one.
[s]
(the default) or container.
[s]
As world_net: guest (the default), lan, full, or none. On a dom0 with no network, none only. A session belongs to an A/B world, never to a rescue world or a decoy.
[s]
, graphics, or compute: whether this VM takes the box's held GPU whole, and with compute for computing too, as session_gpu in scrotwmos.conf(5). The default is none. A container cannot.
[s]
Package sets, as for a world. The default is the world's.
[s]
More packages, as for a world. The default is the world's.
[s]
or no: whether the session is in its world's share. The default is no.

These keys are for byol.

The login user, a username by the rule of world_users. Optional: swmtool plan writes none, and install asks for it beside its password, at the end.
The login password as a crypt(3) hash: SHA512crypt, $6$rounds=n$salt$hash, with n at least 1000000. A cheaper hash is refused: it is of the disk's password too. Make one with
openssl passwd -6 -salt 'rounds=1000000$<salt>'
Optional: swmtool plan writes none, and install asks for the password, twice, as a dom0's, and makes the hash. A plan that holds one is a secret: the hash can be attacked offline. byol is always encrypted, by this one password: the login's, the boot's, and the disk's. The password itself never comes from the plan. Install takes it as --passphrase-file in swmtool(8) says. It refuses one that is not the one the hash is of. There is no encrypt key: a plan that has one is refused.
Package sets, as for a world. The default is shell.
(the default) for a dark desktop: Firefox, GTK (gvim, menus), and Chromium, set at each start of the compositor; or no. A dom0 plan with it is refused.
A serial console, such as ttyS0,115200: a serial port, not a VT, then optionally a comma and the speed, with the kernel's parity, bits, and flow after it. The kernel's console goes to the port, and the runit service swm-getty-port asks for a login there at the speed, 9600 when none is given. A dom0 plan with it is refused.
(the default), the password opens the disk; yes, the TPM opens it, the password the fallback; or password, the TPM and the password together open it, the recovery phrase the fallback. The install adds the TPM's slots and its key and seals nothing. The first boot asks for the password and then seals; with password, that seal takes the password's own slots out. With password, the first boot shows the recovery phrase, 12 words, after the password, and waits for a key; it does so until the seal. On a box with no TPM 2.0, install refuses the plan before the disk is touched. A dom0 plan with it is refused.
The place a restore takes the root from: an absolute path to a directory that the user mounted before the install, the directory that swmtool tt place named on the old box. It can be on a USB disk, an NFS export, an SMB share, or any other file system. The install then lays the new disk out, pulls the root from the place, and fills nothing: the root holds its packages, its user, and its settings. The place's password comes from --place-passwords or is asked; see swmtool(8). The path is checked whole before the disk is touched. The answer's user must be an account of the restored root. It needs restore_hour. A dom0 plan with it is refused.
The hour of the copy to restore, YYYYMMDDTHHZ, as swmtool tt status shows the place's newest copy. It needs restore.

byol takes no world keys, and a dom0 takes none of these. A byol can have up to nine sessions besides host, the byol itself, which keeps every workspace that no session takes and at least one. Each session's keys take its name as the selector; the name follows the world name's rule.

[s]
or vm: the session and its kind. A container's root is /srv/s, and its home is /var/lib/scrotwmos/home/s, bound at /home/s. A VM's disk is /var/lib/scrotwmos/vm/s.img, an xfs on a thin 32G file. Session i, in the order of the plan, runs as uid 500001 + i.
[s]
The session's workspaces, as world_session_ws. Required. No two sessions share a workspace.
[s]
As world_net: guest (the default), lan, full, or none. A container with a network is routed by the net VM when one runs with a network card. Otherwise, the host routes it as a VM.
[s]
Package sets, as for a world, but not rescue. The default is shell.
[s]
More packages, as for a world.
[s]
or no (the default): whether the session is in the share, /share, which is made when a session joins it: owned by root, group 510000, mode 3770.

An appliance with an everyday world, a VM for development on workspaces 4 to 6, and a rescue world:

base = dom0
keyboard = us
disk = /dev/nvme0n1
timezone = UTC
hostname = orchard
allow_hotplug = yes
world[ab] = ab
world_users[ab] = alice,aliceb
world_packages[ab] = shell,firefox
world_session[development] = ab
world_session_ws[development] = 4-6
world_session_packages[development] = shell,go-development
world[rescue] = rescue
world_users[rescue] = rescue

A byol with two containers for agents, sharing /share, and a VM on workspace 5:

base = byol
keyboard = us
disk = /dev/nvme0n1
timezone = UTC
user = alice
password_hash = $6$...
session[agent-a] = container
session_ws[agent-a] = 3
session_share[agent-a] = yes
session[agent-b] = container
session_ws[agent-b] = 4
session_share[agent-b] = yes
session[sandbox] = vm
session_ws[sandbox] = 5

scrotwmos.conf(5), scrotwmos(7), swm-tt(8), swmtool(8)

Marco Peereboom <marco@peereboom.us>

November 5, 2026 Void Linux