2023-12-02 00:43:26 -07:00
|
|
|
;; This is an operating system configuration template
|
|
|
|
;; for a "bare bones" setup, with no X11 display server.
|
|
|
|
|
|
|
|
(use-modules (gnu)
|
2023-12-02 20:02:34 -07:00
|
|
|
(metznet aws)
|
2023-12-02 00:43:26 -07:00
|
|
|
(gnu services shepherd)
|
2023-12-02 20:02:34 -07:00
|
|
|
(gnu services networking)
|
|
|
|
(gnu services ssh)
|
|
|
|
(gnu packages ssh)
|
|
|
|
(gnu packages python-web)
|
|
|
|
(gnu packages shells))
|
2023-12-02 00:43:26 -07:00
|
|
|
|
|
|
|
(operating-system
|
|
|
|
(host-name "guix-ami")
|
|
|
|
(timezone "America/Edmonton")
|
|
|
|
(locale "en_US.utf8")
|
|
|
|
(bootloader (bootloader-configuration
|
|
|
|
(bootloader grub-minimal-bootloader)
|
|
|
|
(targets '("/dev/nvme1n1"))))
|
2023-12-03 18:49:19 -07:00
|
|
|
(swap-devices (list (swap-space (target (file-system-label "guix-swap")))))
|
2023-12-02 00:43:26 -07:00
|
|
|
(file-systems (cons (file-system
|
|
|
|
(device (file-system-label "guix-data"))
|
|
|
|
(mount-point "/")
|
|
|
|
(type "ext4")) %base-file-systems))
|
|
|
|
(groups (cons (user-group
|
|
|
|
(system? #t)
|
2023-12-02 20:02:34 -07:00
|
|
|
(name "aws")) %base-groups))
|
2023-12-02 00:43:26 -07:00
|
|
|
(users (cons (user-account
|
|
|
|
(name "aws")
|
2023-12-02 20:02:34 -07:00
|
|
|
(group "aws")
|
2023-12-03 15:10:47 -07:00
|
|
|
(password (crypt "aws" "$6$change"))
|
2023-12-02 00:43:26 -07:00
|
|
|
(shell (file-append zsh "/bin/zsh"))) %base-user-accounts))
|
|
|
|
|
|
|
|
(sudoers-file (plain-file "sudoers"
|
|
|
|
(string-join (list "Defaults mail_badpass"
|
|
|
|
"root ALL=(ALL:ALL) ALL"
|
2023-12-02 20:02:34 -07:00
|
|
|
"%aws ALL=(ALL:ALL) ALL" "")
|
2023-12-02 00:43:26 -07:00
|
|
|
"\n")))
|
|
|
|
|
|
|
|
(packages (cons* openssh awscli %base-packages))
|
|
|
|
|
|
|
|
(services
|
|
|
|
(cons* (service dhcp-client-service-type)
|
2023-12-02 14:49:40 -07:00
|
|
|
(service aws-service-type)
|
2023-12-02 00:43:26 -07:00
|
|
|
(service openssh-service-type
|
2023-12-02 14:49:40 -07:00
|
|
|
(openssh-configuration (port-number 22)
|
|
|
|
(password-authentication? #f)))
|
|
|
|
%base-services)))
|
2023-12-02 00:43:26 -07:00
|
|
|
|