summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Paśnikowski <marek@marekpasnikowski.pl>2026-03-24 17:20:14 +0100
committerMarek Paśnikowski <marek@marekpasnikowski.pl>2026-03-24 17:20:52 +0100
commitce47e12ef97a8b4f095747eb864244186481b363 (patch)
tree7f4a109250404a5a022ccd28a472462fb51d67f5
parent223b36db2c72dcd158e4af9eca4e3cfbcbbaef3a (diff)
(deployment systems akashi): simplify definition of system
-rw-r--r--deployment/systems/akashi.scm42
1 files changed, 17 insertions, 25 deletions
diff --git a/deployment/systems/akashi.scm b/deployment/systems/akashi.scm
index 9f490c6..c6687b6 100644
--- a/deployment/systems/akashi.scm
+++ b/deployment/systems/akashi.scm
@@ -18,6 +18,8 @@
#:prefix gnu:system:)
#:use-module ((gnu system file-systems)
#:prefix gnu:system:file-systems:)
+ #:use-module ((gnu system keyboard)
+ #:prefix gnu:system:keyboard:)
#:use-module ((gnu system linux-initrd)
#:prefix gnu:system:linux-initrd:)
#:use-module ((gnu system locale)
@@ -44,13 +46,8 @@
(define host-name*
"akashi")
-(define (file-systems)
- (cons* root-partition
- gnu:system:file-systems:%base-file-systems))
-
-(define keyboard-layout*
- ((@ (gnu system keyboard) keyboard-layout)
- "pl"))
+(define system-keyboard-layout
+ (gnu:system:keyboard:keyboard-layout "pl"))
(define offload-hub
#~(build-machine
@@ -72,20 +69,12 @@
gnu:services:base:guix-service-type
guix-offload-targets))
-(define (services)
- (let*
- ( (home-environments `((,uid1000-name ,uid1000-home-environment)))
- (guix-home (gnu:services:service
- gnu:services:guix:guix-home-service-type
- home-environments)))
- (append sovereign:systems:%sovereign-services
- (list guix-home
- offload-extension))))
-
-(define users
- (list uid1000-account))
+(define home-environments
+ `((,uid1000-name ,uid1000-home-environment)))
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+(define guix-home
+ (gnu:services:service gnu:services:guix:guix-home-service-type
+ home-environments))
(define-public system
(gnu:system:operating-system
@@ -95,19 +84,20 @@
"thinkpad_acpi.fan='level 7'"
gnu:system:%default-kernel-arguments))
(hurd #f)
- (bootloader (machines:thinkpad-x200:bootloader-configuration* keyboard-layout*))
+ (bootloader (machines:thinkpad-x200:bootloader-configuration* system-keyboard-layout))
(label (sovereign:systems:operating-system-label* host-name*
gnu:system:this-operating-system))
- (keyboard-layout keyboard-layout*)
+ (keyboard-layout system-keyboard-layout)
(initrd gnu:system:linux-initrd:base-initrd)
(initrd-modules gnu:system:linux-initrd:%base-initrd-modules)
(firmware (list))
(host-name host-name*)
(hosts-file #f)
(mapped-devices (list))
- (file-systems (file-systems))
+ (file-systems (cons* root-partition
+ gnu:system:file-systems:%base-file-systems))
(swap-devices (machines:thinkpad-x200:swap-devices* host-name*))
- (users users)
+ (users (list uid1000-account))
(groups gnu:system:shadow:%base-groups)
(skeletons (gnu:system:shadow:default-skeletons))
(issue (@@ (gnu system)
@@ -119,7 +109,9 @@
(locale-libcs gnu:system:locale:%default-locale-libcs)
(name-service-switch gnu:system:nss:%default-nss)
(essential-services (gnu:system:operating-system-default-essential-services gnu:system:this-operating-system))
- (services (services))
+ (services (cons* guix-home
+ offload-extension
+ sovereign:systems:%sovereign-services))
(pam-services (gnu:system:pam:base-pam-services))
(privileged-programs gnu:system:%default-privileged-programs)
(setuid-programs gnu:system:%setuid-programs)