;; This is an operating system configuration template ;; for a "desktop" setup with GNOME and Xfce where the ;; root partition is encrypted with LUKS. (use-modules (gnu) (gnu system nss) (gnu packages linux) (gnu packages libusb) (sys-kernel linux linux)) (use-service-modules networking mcron desktop virtualization) (use-package-modules wm ssh shells certs) (operating-system (host-name "example") (timezone "Pacific/Auckland") (locale "en_US.UTF-8") (kernel linux-4.15.15) ;; Assuming /dev/sdX is the target hard disk, and "my-root" ;; is the label of the target root file system. (bootloader (grub-configuration (target "/dev/sda"))) ;; Specify a mapped device for the encrypted root partition. ;; The UUID is that returned by 'cryptsetup luksUUID'. (mapped-devices (list (mapped-device (source (uuid "")) (target "root-partition") (type luks-device-mapping)) (mapped-device (source (uuid "")) (target "home-partition") (type luks-device-mapping)))) (file-systems (cons* (file-system (device "/dev/mapper/root-partition") (title 'device) (mount-point "/") (type "ext4")) (file-system (device "/dev/mapper/home-partition") (title 'device) (mount-point "/home") (type "ext4")) %base-file-systems)) (users (cons (user-account (name "user") (comment "the user") (group "users") (supplementary-groups '("wheel" "netdev" "audio" "video" "kvm" "libvirt")) (home-directory "/home/user") (shell #~(string-append #$zsh "/bin/zsh"))) %base-user-accounts)) ;; This is where we specify system-wide packages. (packages (cons* awesome ;window managers tlp ;power management nss-certs ;for HTTPS access cryptsetup openssh acpi %base-packages)) (services (cons* (mate-desktop-service) (simple-service 'mtp udev-service-type (list libmtp)) (service libvirt-service-type (libvirt-configuration (unix-sock-group "libvirt"))) (service virtlog-service-type (virtlog-configuration (max-clients 1000))) %desktop-services)) ;; Allow resolution of '.local' host names with mDNS. (name-service-switch %mdns-host-lookup-nss))