Example 1. Create a user "waldo" in the administrator group
"wheel", and assign 500 MiB disk space to them.
homectl create waldo --real-name="Waldo McWaldo" -G wheel --disk-size=500M
Example 2. Create a user "wally" on a USB stick, and assign a
maximum of 500 concurrent tasks to them.
homectl create wally --real-name="Wally McWally" --image-path=/dev/disk/by-id/usb-SanDisk_Ultra_Fit_476fff954b2b5c44-0:0 --tasks-max=500
Example 3. Change nice level of user "odlaw" to +5 and make sure
the environment variable
$SOME is set to the string "THING" for
them on login.
homectl update odlaw --nice=5 --setenv=SOME=THING
Example 4. Set up authentication with a YubiKey security token
using PKCS#11/PIV:
# Clear the Yubikey from any old keys (careful!)
ykman piv reset
# Generate a new private/public key pair on the device, store the public key in 'pubkey.pem'.
ykman piv generate-key -a RSA2048 9d pubkey.pem
# Create a self-signed certificate from this public key, and store it on the device.
ykman piv generate-certificate --subject "Knobelei" 9d pubkey.pem
# We don't need the public key on disk anymore
rm pubkey.pem
# Allow the security token to unlock the account of user 'lafcadio'.
homectl update lafcadio --pkcs11-token-uri=auto
Example 5. Set up authentication with a FIDO2 security token:
# Allow a FIDO2 security token to unlock the account of user 'nihilbaxter'.
homectl update nihilbaxter --fido2-device=auto