aboutsummaryrefslogtreecommitdiff
path: root/tw/system.scm
diff options
context:
space:
mode:
authorTimo Wilken2024-05-13 18:27:53 +0200
committerTimo Wilken2024-05-13 18:27:53 +0200
commit02807429549df9a134edf0a3b54ddd3a3c625631 (patch)
treec9a0e8e95f63d66e9aa7e8463aee388fa6ed8b15 /tw/system.scm
parentd502ca9ce0e16b538e08329c1876e80680ecd559 (diff)
Integrate CERN laptop configuration into main system config
Diffstat (limited to 'tw/system.scm')
-rw-r--r--tw/system.scm19
1 files changed, 12 insertions, 7 deletions
diff --git a/tw/system.scm b/tw/system.scm
index 30710b8f..e706d84c 100644
--- a/tw/system.scm
+++ b/tw/system.scm
@@ -52,9 +52,10 @@
("pi3.twilken.net" . 51022)
("lap.twilken.net" . 22)
("frm.twilken.net" . 22)
- ("btl.twilken.net" . 23022)))
+ ("btl.twilken.net" . 23022)
+ ("twilkenlaptop.cern.ch" . 22022)))
-(define (tw-openssh-service host-name)
+(define (tw-openssh-service host-name work-system?)
"Configure the SSH server for remote login."
;; SSH login, allowing access only for me. To give more public keys
;; access, extend `openssh-service-type'.
@@ -67,9 +68,12 @@
(password-authentication? #f)
(accepted-environment '("LANG" "LC_*"))
(authorized-keys
- `(("timo"
- ,(local-file "system/files/timo.pub")
- ,(local-file "system/files/timo-phone-gpg.pub")))))))
+ (if work-system?
+ `(("twilken"
+ ,(local-file "system/files/timo-cern.pub")))
+ `(("timo"
+ ,(local-file "system/files/timo.pub")
+ ,(local-file "system/files/timo-phone-gpg.pub"))))))))
(define-public (tw-login-configuration config)
"Patch the given `login-configuration' to my liking."
@@ -213,6 +217,7 @@ ACTION!=\"remove\", SUBSYSTEM==\"leds\", GROUP=\"video\", MODE=\"0664\"
(define* (enduser-system-services
#:key
host-name cores wireless-interface backlight-device
+ (work-system? #f)
(xorg-extra-modules '())
(xorg-drivers '()))
@@ -323,7 +328,7 @@ ACTION!=\"remove\", SUBSYSTEM==\"leds\", GROUP=\"video\", MODE=\"0664\"
(tw-wireguard-configuration
(this-host host-name)))
- (tw-openssh-service host-name)
+ (tw-openssh-service host-name work-system?)
;; Since Guix 953c65ffdd4, build-machines can be directly specified in
;; `guix-configuration'. However, this doesn't allow the dynamic
@@ -383,7 +388,7 @@ ACTION!=\"remove\", SUBSYSTEM==\"leds\", GROUP=\"video\", MODE=\"0664\"
(gdm-configuration
(inherit config)
(auto-login? #f)
- (default-user "timo")
+ (default-user (if work-system? "twilken" "timo"))
(xorg-configuration xorg-config)))
(geoclue-service-type