commit 1f43b49b0a548463784fe7f10378ef8aa60d9559
parent 937b2f739d42ebb8665593268f24f91278a54659
Author: Luke Willis <lukejw@loquat.dev>
Date: Mon, 15 Dec 2025 20:24:15 -0500
Switch to ngnix
Diffstat:
1 file changed, 15 insertions(+), 3 deletions(-)
diff --git a/mt/system/andrew.scm b/mt/system/andrew.scm
@@ -5,7 +5,9 @@
#:use-module (gnu bootloader)
#:use-module (gnu bootloader grub)
#:use-module (gnu services)
+ #:use-module (gnu services certbot)
#:use-module (gnu services version-control)
+ #:use-module (gnu services web)
#:use-module (gnu system)
#:use-module (gnu system keyboard)
#:use-module (gnu system shadow)
@@ -14,7 +16,6 @@
#:use-module (nongnu packages linux)
#:use-module (nongnu system linux-initrd)
#:use-module (mt services)
- #:use-module (mt services web)
#:use-module (mt system)
#:export (andrew-os))
@@ -74,10 +75,21 @@ Welcome to \"andrew\" the, first MonasTech server.
;; TODO: Add git home environment with custom commands
;; TODO: Create special service that creates git user, group and environment
- ;; TODO: Figure out how to glue certbot, quark and hitch together
(services
(append
- (list (service quark-service-type "/var/www/monastech.xyz/")
+ (list (service nginx-service-type
+ (nginx-configuration
+ (server-blocks
+ (list (nginx-server-configuration
+ (server-name '("monastech.xyz" "www.monastech.xyz"))
+ (root "/var/www/monastech.xyz")
+ (ssl-certificate "/etc/dehydrated/certs/monastech.xyz/fullchain.pem")
+ (ssl-certificate-key "/etc/dehydrated/certs/monastech.xyz/privkey.pem")
+ (locations
+ (list (nginx-location-configuration
+ (uri "^~ /.well-known/acme-challenge")
+ (body (list "alias /var/www/dehydrated;"))))))))))
+ ;; TODO: Certbot is weird, write my own service based off dehydrated
(service git-daemon-service-type
(git-daemon-configuration
(base-path "/home/git/repo"))))