[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/04: hydra: Add configuration for hatysa.
From: |
Christopher Baines |
Subject: |
01/04: hydra: Add configuration for hatysa. |
Date: |
Sat, 26 Feb 2022 09:28:21 -0500 (EST) |
cbaines pushed a commit to branch master
in repository maintenance.
commit afbe035d0f0663eb0cca3c5f1dc30c01c627ee65
Author: Christopher Baines <mail@cbaines.net>
AuthorDate: Sat Feb 26 13:59:36 2022 +0000
hydra: Add configuration for hatysa.
Long overdue addition of the configuration for hatysa, a HoneyComb LX2
machine currently building ARM things for bordeaux.guix.gnu.org.
* hydra/hatysa.scm: New file.
---
hydra/hatysa.scm | 185 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 185 insertions(+)
diff --git a/hydra/hatysa.scm b/hydra/hatysa.scm
new file mode 100644
index 0000000..e4a5b82
--- /dev/null
+++ b/hydra/hatysa.scm
@@ -0,0 +1,185 @@
+;; Guix System configuration file for a SolidRun Honeycomb LX2 machine
+;; Copyright © 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
+;; Copyright © 2021 Christopher Baines <mail@cbaines.net>
+;; Released under the GNU GPLv3 or any later version.
+
+(use-modules (guix) (gnu))
+(use-service-modules networking mcron ssh monitoring guix)
+(use-package-modules screen ssh linux certs)
+
+(define (sysadmin name full-name)
+ (user-account
+ (name name)
+ (comment full-name)
+ (group "users")
+ (supplementary-groups '("wheel" "kvm"))
+ (home-directory (string-append "/home/" name))))
+
+(define %accounts
+ (list (sysadmin "cbaines" "Christopher Baines")))
+
+(define %default-extra-linux-options
+ (@@ (gnu packages linux) %default-extra-linux-options))
+(define make-linux-libre*
+ (@@ (gnu packages linux) make-linux-libre*))
+
+(define-public linux-libre-arm64-honeycomb
+ (make-linux-libre* linux-libre-version
+ linux-libre-gnu-revision
+ linux-libre-source
+ '("aarch64-linux")
+ #:extra-version "arm64-generic"
+ #:extra-options
+ (append
+ `(;; needed to fix the RTC on rockchip platforms
+ ("CONFIG_RTC_DRV_RK808" . #t)
+ ;; Pinebook display, battery, charger and usb
+ ("CONFIG_DRM_ANALOGIX_ANX6345" . m)
+ ("CONFIG_CHARGER_AXP20X" . m)
+ ("CONFIG_INPUT_AXP20X_PEK" . m)
+ ("CONFIG_CHARGER_AXP20X" . m)
+ ("CONFIG_BATTERY_AXP20X" . m)
+ ("CONFIG_PINCTRL_AXP209" . m)
+ ("CONFIG_AXP20X_POWER" . m)
+ ("CONFIG_AXP20X_ADC" . m)
+
+ ("CONFIG_GPIO_SYSFS" . #t)
+ ("CONFIG_GPIO_MPC8XXX" . #t)
+ ("CONFIG_NET_PKTGEN" . #t)
+ ("CONFIG_USB_SERIAL" . #t)
+ ("CONFIG_USB_SERIAL_CONSOLE" . #t)
+ ("CONFIG_USB_SERIAL_GENERIC" . #t)
+ ("CONFIG_USB_SERIAL_SIMPLE" . #t)
+ ("CONFIG_USB_SERIAL_FTDI_SIO" . #t)
+ ("CONFIG_USB_ACM" . #t)
+ ("CONFIG_USB_NET_DRIVERS" . #t)
+ ("CONFIG_USB_USBNET" . #t)
+ ("CONFIG_USB_NET_CDCETHER" . #t)
+ ("CONFIG_USB_NET_CDC_NCM" . #t)
+ ("CONFIG_USB_NET_NET1080" . #t)
+ ("CONFIG_USB_NET_CDC_SUBSET_ENABLE" . #t)
+ ("CONFIG_USB_NET_CDC_SUBSET" . #t)
+ ("CONFIG_USB_ARMLINUX" . #t)
+ ("CONFIG_BLK_DEV_NVME" . #t)
+ ("CONFIG_NVMEM_BCM_OCOTP" . #t)
+ ("CONFIG_DRM_AMDGPU" . #t)
+ ("CONFIG_DRM_AMDGPU_SI" . #t)
+ ("CONFIG_DRM_AMDGPU_CIK" . #t)
+ ("CONFIG_DRM_AMDGPU_USERPTR" . #t)
+ ("CONFIG_DRM_AMD_DC" . #t)
+ ("CONFIG_CHASH" . #t)
+ ("CONFIG_PMBUS" . #t)
+ ("CONFIG_SENSORS_PMBUS" . #t)
+ ("CONFIG_REGULATOR" . #t)
+ ("CONFIG_REGULATOR_FIXED_VOLTAGE" . #t)
+ ("CONFIG_REGULATOR_PWM" . #t)
+ ("CONFIG_SENSORS_AMC6821" . #t)
+ ("CONFIG_SENSORS_LM90" . #t)
+ ("CONFIG_SENSORS_LTC2978" . #t)
+ ("CONFIG_SENSORS_LTC2978_REGULATOR" . #t)
+ ("CONFIG_TMPFS" . #t)
+ ("CONFIG_TMPFS_POSIX_ACL" . #t)
+ ("CONFIG_TMPFS_XATTR" . #t)
+ ("CONFIG_BLK_DEV_RAM_SIZE=5242" . #t)
+ ("CONFIG_POWER_RESET_GPIO" . #t)
+ ("CONFIG_CRYPTO_USER_API_HASH" . #t)
+ ("CONFIG_CRYPTO_USER_API_SKCIPHER" . #t)
+ ("CONFIG_CRYPTO_USER_API_RNG" . #t)
+ ("CONFIG_CRYPTO_USER_API_AEAD" . #t)
+
+ ;; Pinebook PRO battery and sound support
+ ("CONFIG_BATTERY_CW2015" . m)
+ ("CONFIG_CHARGER_GPIO" . m)
+ ("CONFIG_SND_SOC_ES8316" . m))
+ %default-extra-linux-options)))
+
+(operating-system
+ (host-name "hatysa")
+ (timezone "Europe/London")
+ (locale "en_US.utf8")
+
+ (bootloader (bootloader-configuration
+ (bootloader grub-efi-bootloader)
+ (targets '("/boot/efi"))))
+
+ (kernel linux-libre-arm64-honeycomb)
+ (initrd-modules '())
+ (kernel-arguments '("arm-smmu.disable_bypass=0"
+ "iommu.passthrough=1"))
+
+ (file-systems (cons* (file-system
+ (device "/dev/nvme0n1p2")
+ (mount-point "/")
+ (type "ext4"))
+ (file-system
+ (device "/dev/sda1")
+ (mount-point "/var/lib/nars")
+ (type "ext4"))
+ (file-system
+ (device "/dev/nvme0n1p1")
+ (mount-point "/boot/efi")
+ (type "vfat"))
+ %base-file-systems))
+
+ (swap-devices (list (swap-space (target "/swapfile"))))
+
+ (users (append %accounts %base-user-accounts))
+ (packages
+ (cons* screen
+ nss-certs
+ %base-packages))
+ (services
+ (cons* (service dhcp-client-service-type)
+
+ (service agetty-service-type
+ (agetty-configuration
+ (tty "ttyAMA0")
+ (keep-baud? #t)
+ (term "vt220")
+ (baud-rate "115200,38400,9600")))
+
+ (service openssh-service-type
+ (openssh-configuration
+ (password-authentication? #f)))
+
+ (service ntp-service-type)
+ (service prometheus-node-exporter-service-type)
+
+ (service guix-build-coordinator-agent-service-type
+ (guix-build-coordinator-agent-configuration
+ (coordinator "https://coordinator.bayfront.guix.gnu.org")
+ (authentication
+ (guix-build-coordinator-agent-password-file-auth
+ (uuid "bc5f3585-03f9-4ab3-8604-6acc89512fba")
+ (password-file
+ "/etc/guix-build-coordinator-agent-password")))
+ (max-parallel-builds 12)
+ (systems '("aarch64-linux" "armhf-linux"))
+ (derivation-substitute-urls
+ (list "https://data.guix.gnu.org"))
+ (non-derivation-substitute-urls
+ (list "https://bordeaux.guix.gnu.org"))))
+
+ (service nar-herder-service-type
+ (nar-herder-configuration
+ (mirror "https://bordeaux.guix.gnu.org")
+ (storage "/var/lib/nars")))
+
+ (modify-services %base-services
+ (guix-service-type
+ config => (guix-configuration
+ (inherit config)
+ (substitute-urls
+ '("https://bordeaux.guix.gnu.org"))
+
+ (max-silent-time (* 12 3600))
+ (timeout (* 24 3600))
+
+ (build-accounts 32)
+
+ (authorized-keys
+ (cons*
+ ;; for substituting derivations
+ (local-file "keys/guix/data.guix.gnu.org.pub")
+ %default-authorized-guix-keys))))))))
+