|
|
|
@ -7,29 +7,22 @@
|
|
|
|
|
#:use-module (gnu services certbot)
|
|
|
|
|
#:use-module (gnu services slapd)
|
|
|
|
|
|
|
|
|
|
#:export (ldap.metznet.ca))
|
|
|
|
|
#:export (ldap.metznet.ca ldap-services))
|
|
|
|
|
|
|
|
|
|
(define-public ldap-services
|
|
|
|
|
(append (list (service certbot-service-type
|
|
|
|
|
(certbot-configuration (email "admin@metznet.ca")
|
|
|
|
|
(certificates (list (certificate-configuration
|
|
|
|
|
(domains '
|
|
|
|
|
("ldap.guix.metznet.ca")))))))
|
|
|
|
|
(service slapd-service-type
|
|
|
|
|
(slapd-configuration (uris
|
|
|
|
|
"ldap:// ldapi:// ldaps:// ldapis://"))))
|
|
|
|
|
%metznet-server-services))
|
|
|
|
|
|
|
|
|
|
(define-public ldap.metznet.ca
|
|
|
|
|
(operating-system
|
|
|
|
|
(inherit %metznet-base-server-system)
|
|
|
|
|
(host-name "ldap.guix.metznet.ca")
|
|
|
|
|
(services
|
|
|
|
|
(append (list (service certbot-service-type
|
|
|
|
|
(certbot-configuration (email "admin@metznet.ca")
|
|
|
|
|
(certificates (list (certificate-configuration
|
|
|
|
|
(domains '
|
|
|
|
|
("ldap.guix.metznet.ca")))))))
|
|
|
|
|
(service slapd-service-type
|
|
|
|
|
(slapd-configuration (uris
|
|
|
|
|
"ldap:// ldapi:// ldaps:// ldapis://")
|
|
|
|
|
(backups (let ((slapd-seeds (getenv
|
|
|
|
|
"SLAPD_SEEDS")))
|
|
|
|
|
(if slapd-seeds
|
|
|
|
|
(map (lambda (ldif)
|
|
|
|
|
(local-file
|
|
|
|
|
ldif))
|
|
|
|
|
(string-split
|
|
|
|
|
slapd-seeds
|
|
|
|
|
#\:))
|
|
|
|
|
'()))))))
|
|
|
|
|
%metznet-server-services))))
|
|
|
|
|
ldap-services)))
|
|
|
|
|