From 4c4858f2a4c6db306ccb59be9860cc4bafc8fd18 Mon Sep 17 00:00:00 2001 From: Daniel Ziltener Date: Mon, 11 Dec 2023 12:54:43 +0100 Subject: [PATCH] . --- Makefile | 7 +++++ channels.scm | 18 ++++++++++++ config.org | 70 +++++++++++++++++++++++++++++++++++------------ config.scm | 21 +++++++------- keys/non-guix.pub | 7 +++++ 5 files changed, 96 insertions(+), 27 deletions(-) create mode 100644 Makefile create mode 100644 channels.scm create mode 100644 keys/non-guix.pub diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..7021395 --- /dev/null +++ b/Makefile @@ -0,0 +1,7 @@ +~/.config/guix/channels.scm: + mkdir -p ~/.config/guix + cp channels.scm ~/.config/guix/channels.scm + +install: + guix archive --authorize < signing-key.pub + guix system reconfigure ./config.scm --substitute-urls='https://ci.guix.gnu.org https://bordeaux.guix.gnu.org https://substitutes.nonguix.org' diff --git a/channels.scm b/channels.scm new file mode 100644 index 0000000..02920ca --- /dev/null +++ b/channels.scm @@ -0,0 +1,18 @@ +;; Channels + +;; This adds the Nonguix channel. + + +;; [[file:config.org::*Channels][Channels:1]] +;; Copy this to ~/.config/guix/channels.scm. +(cons* (channel + (name 'nonguix) + (url "https://gitlab.com/nonguix/nonguix") + ;; Enable signature verification: + (introduction + (make-channel-introduction + "897c1a470da759236cc11798f4e0a5f7d4d59fbc" + (openpgp-fingerprint + "2A39 3FFF 68F4 EF7A 3D29 12AF 6F51 20A0 22FB B2D5")))) + %default-channels) +;; Channels:1 ends here diff --git a/config.org b/config.org index a902692..4a92e3d 100644 --- a/config.org +++ b/config.org @@ -7,6 +7,18 @@ (org-babel-lob-ingest "./library.org") #+end_src +* Makefile + +#+begin_src makefile :tangle Makefile + ~/.config/guix/channels.scm: + mkdir -p ~/.config/guix + cp channels.scm ~/.config/guix/channels.scm + + install: + guix archive --authorize < signing-key.pub + guix system reconfigure ./config.scm --substitute-urls='https://ci.guix.gnu.org https://bordeaux.guix.gnu.org https://substitutes.nonguix.org' +#+end_src + * Modules #+NAME: module-list @@ -22,6 +34,8 @@ - gnu services virtualization - gnu services xorg - gnu system nss +- nongnu packages linux +- nongnu system linux-initrd #+begin_src scheme :noweb yes :exports none :results code pp :tangle config.scm <> @@ -89,6 +103,24 @@ As a sibling to the former, the variable ~%local-swap~ does the same with the sw (interaction-environment)))))) #+end_src +** Channels + +This adds the Nonguix channel. + +#+begin_src scheme :tangle channels.scm + ;; Copy this to ~/.config/guix/channels.scm. + (cons* (channel + (name 'nonguix) + (url "https://gitlab.com/nonguix/nonguix") + ;; Enable signature verification: + (introduction + (make-channel-introduction + "897c1a470da759236cc11798f4e0a5f7d4d59fbc" + (openpgp-fingerprint + "2A39 3FFF 68F4 EF7A 3D29 12AF 6F51 20A0 22FB B2D5")))) + %default-channels) +#+end_src + ** Packages #+NAME: root-packages @@ -147,25 +179,26 @@ These services are unmodified, or have just few settings. *** Modified Desktop Services +#+NAME: nonguix-pubkey +#+begin_src scheme :tangle keys/non-guix.pub :mkdirp yes + (public-key (ecc (curve Ed25519) (q #C1FD53E5D4CE971933EC50C9F307AE2171A2D3B52C804642A7A35F84F3A4EA98#))) +#+end_src + #+NAME: root-modified-desktop-services #+begin_src scheme :exports none :results code - (modify-services - %desktop-services - (delete login-service-type) - (delete mingetty-service-type) - (delete console-font-service-type) - (guix-service-type config => (guix-configuration - (inherit config) - (substitute-urls - (append (list "https://substitutes.nonguix.org") - %default-substitute-urls)) - (authorized-keys - (append (list (plain-file "non-guix.pub" - "(public-key - (ecc - (curve Ed25519) - (q #C1FD53E5D4CE971933EC50C9F307AE2171A2D3B52C804642A7A35F84F3A4EA98#))) - "))))))) + (modify-services + %desktop-services + (delete login-service-type) + (delete mingetty-service-type) + (delete console-font-service-type) + (guix-service-type config => (guix-configuration + (inherit config) + (substitute-urls + (append (list "https://substitutes.nonguix.org") + %default-substitute-urls)) + (authorized-keys + (append (list (plain-file "non-guix.pub" + "<>"))))))) #+end_src *** Greeter Service @@ -224,6 +257,9 @@ This is the full operating system specification. (locale "de_DE.utf8") (keyboard-layout (keyboard-layout "de" #:options '("caps:swapescape"))) + (kernel linux) + (initrd microcode-initrd) + (firmware (list linux-firmware)) (bootloader (bootloader-configuration (bootloader grub-efi-bootloader) diff --git a/config.scm b/config.scm index fdbd328..800c4e9 100644 --- a/config.scm +++ b/config.scm @@ -13,10 +13,12 @@ ;; - gnu services virtualization ;; - gnu services xorg ;; - gnu system nss +;; - nongnu packages linux +;; - nongnu system linux-initrd ;; [[file:config.org::*Modules][Modules:1]] -nil +(use-modules (gnu) (gnu image) (gnu services authentication) (gnu services base) (gnu services dbus) (gnu services desktop) (gnu services linux) (gnu services networking) (gnu services pm) (gnu services virtualization) (gnu services xorg) (gnu system nss) (nongnu packages linux) (nongnu system linux-initrd)) ;; Modules:1 ends here ;; Service Modules @@ -27,7 +29,7 @@ nil ;; [[file:config.org::*Service Modules][Service Modules:1]] -nil +(use-service-modules desktop xorg) ;; Service Modules:1 ends here ;; Package Modules @@ -46,7 +48,7 @@ nil ;; [[file:config.org::*Package Modules][Package Modules:1]] -nil +(use-package-modules bootloaders certs emacs emacs-xyz fonts readline terminals version-control wm xorg) ;; Package Modules:1 ends here ;; File System @@ -97,6 +99,9 @@ nil (locale "de_DE.utf8") (keyboard-layout (keyboard-layout "de" #:options '("caps:swapescape"))) + (kernel linux) + (initrd microcode-initrd) + (firmware (list linux-firmware)) (bootloader (bootloader-configuration (bootloader grub-efi-bootloader) @@ -115,7 +120,7 @@ nil %base-user-accounts)) (packages (append - nil + (list emacs emacs-desktop-environment font-terminus git hwdata nss-certs readline swayfx) %base-packages)) (services (append @@ -131,12 +136,8 @@ nil %default-substitute-urls)) (authorized-keys (append (list (plain-file "non-guix.pub" - "(public-key - (ecc - (curve Ed25519) - (q #C1FD53E5D4CE971933EC50C9F307AE2171A2D3B52C804642A7A35F84F3A4EA98#))) - "))))))) - nil + "<>"))))))) + (list (service tlp-service-type (tlp-configuration)) (service thermald-service-type (thermald-configuration (adaptive? #t))) (service bluetooth-service-type (bluetooth-configuration)) (service earlyoom-service-type (earlyoom-configuration (minimum-available-memory 5) (minimum-free-swap 5))) (service inputattach-service-type (inputattach-configuration)) (service libvirt-service-type (libvirt-configuration (unix-sock-group "libvirt"))) (service fstrim-service-type (fstrim-configuration)) (service fprintd-service-type (fprintd-configuration))) (list (service greetd-service-type (greetd-configuration diff --git a/keys/non-guix.pub b/keys/non-guix.pub new file mode 100644 index 0000000..e0f8149 --- /dev/null +++ b/keys/non-guix.pub @@ -0,0 +1,7 @@ +;; Modified Desktop Services + +;; #+NAME: nonguix-pubkey + +;; [[file:../config.org::nonguix-pubkey][nonguix-pubkey]] +(public-key (ecc (curve Ed25519) (q #C1FD53E5D4CE971933EC50C9F307AE2171A2D3B52C804642A7A35F84F3A4EA98#))) +;; nonguix-pubkey ends here