From bd924c7e4bc2e9e72c205192d8b9d557d9a400c6 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Wed, 19 Feb 2025 07:52:01 -0300 Subject: etc/guix/system.scm: Add "host-name" and "wg-ipaddr" variables --- etc/guix/system.scm | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/etc/guix/system.scm b/etc/guix/system.scm index af9b24a..f5c3b38 100644 --- a/etc/guix/system.scm +++ b/etc/guix/system.scm @@ -33,6 +33,10 @@ (heredoc:enable-syntax) +(define host-name "novinho") +(define wg-ipaddr "10.0.0.5") + + ;; Implement wireless printing before sending upstream (define-public epson-L365 (package @@ -123,7 +127,7 @@ Seiko Epson Color Ink Jet Printers.") (timezone "America/Sao_Paulo") (keyboard-layout (keyboard-layout "br" #:options '("caps:swapescape" "esperanto:qwerty"))) - (host-name "velhinho") + (host-name host-name) (users (append (list @@ -163,7 +167,7 @@ Seiko Epson Color Ink Jet Printers.") (simple-service 'add-wireguard-aliases hosts-service-type (list (host "10.0.0.0" "toph") - (host "10.0.0.1" host-name))) + (host wg-ipaddr host-name))) (service q:local-postfix-service-type (q:postfix-configuration (main.cf-extra #"- @@ -184,7 +188,9 @@ Seiko Epson Color Ink Jet Printers.") ("andreh" "eu@euandre.org"))) (service wireguard-service-type (wireguard-configuration - (addresses '("10.0.0.1/32")) + (addresses + (list + (string-append wg-ipaddr "/32"))) (peers (list (wireguard-peer -- cgit v1.2.3