diff options
Diffstat (limited to 'gnu/services')
-rw-r--r-- | gnu/services/cuirass.scm | 8 | ||||
-rw-r--r-- | gnu/services/databases.scm | 6 | ||||
-rw-r--r-- | gnu/services/dns.scm | 14 | ||||
-rw-r--r-- | gnu/services/linux.scm | 3 | ||||
-rw-r--r-- | gnu/services/nfs.scm | 4 | ||||
-rw-r--r-- | gnu/services/xorg.scm | 37 |
6 files changed, 59 insertions, 13 deletions
diff --git a/gnu/services/cuirass.scm b/gnu/services/cuirass.scm index 2d0bf47b48..1cebbfcb6e 100644 --- a/gnu/services/cuirass.scm +++ b/gnu/services/cuirass.scm @@ -109,6 +109,8 @@ (default #f)) (fallback? cuirass-configuration-fallback? ;boolean (default #f)) + (zabbix-uri cuirass-configuration-zabbix-uri ;string + (default #f)) (extra-options cuirass-configuration-extra-options (default '()))) @@ -129,6 +131,7 @@ (use-substitutes? (cuirass-configuration-use-substitutes? config)) (one-shot? (cuirass-configuration-one-shot? config)) (fallback? (cuirass-configuration-fallback? config)) + (zabbix-uri (cuirass-configuration-zabbix-uri config)) (extra-options (cuirass-configuration-extra-options config))) `(,(shepherd-service (documentation "Run Cuirass.") @@ -170,6 +173,11 @@ "--interval" #$(number->string interval) #$@(if use-substitutes? '("--use-substitutes") '()) #$@(if fallback? '("--fallback") '()) + #$@(if zabbix-uri + (list (string-append + "--zabbix-uri=" + zabbix-uri)) + '()) #$@extra-options) #:user #$user diff --git a/gnu/services/databases.scm b/gnu/services/databases.scm index c11898693f..d908b86af8 100644 --- a/gnu/services/databases.scm +++ b/gnu/services/databases.scm @@ -396,12 +396,12 @@ and stores the database cluster in @var{data-directory}." rolname = '" ,name "')) as not_exists;\n" "\\gset\n" "\\if :not_exists\n" -"CREATE ROLE " ,name +"CREATE ROLE \"" ,name "\"" " WITH " ,(format-permissions permissions) ";\n" ,@(if create-database? - `("CREATE DATABASE " ,name - " OWNER " ,name ";\n") + `("CREATE DATABASE \"" ,name "\"" + " OWNER \"" ,name "\";\n") '()) "\\endif\n"))) roles))) diff --git a/gnu/services/dns.scm b/gnu/services/dns.scm index b339eb0619..d4aefe6285 100644 --- a/gnu/services/dns.scm +++ b/gnu/services/dns.scm @@ -256,9 +256,9 @@ (let ((id (knot-key-configuration-id key))) (unless (and (string? id) (not (equal? id ""))) (error-out "key id must be a non empty string."))) - (unless (memq '(#f hmac-md5 hmac-sha1 hmac-sha224 hmac-sha256 hmac-sha384 hmac-sha512) - (knot-key-configuration-algorithm key)) - (error-out "algorithm must be one of: #f, 'hmac-md5, 'hmac-sha1, + (unless (memq (knot-key-configuration-algorithm key) + '(#f hmac-md5 hmac-sha1 hmac-sha224 hmac-sha256 hmac-sha384 hmac-sha512)) + (error-out "algorithm must be one of: #f, 'hmac-md5, 'hmac-sha1, 'hmac-sha224, 'hmac-sha256, 'hmac-sha384 or 'hmac-sha512"))) (define (verify-knot-keystore-configuration keystore) @@ -267,9 +267,9 @@ (let ((id (knot-keystore-configuration-id keystore))) (unless (and (string? id) (not (equal? id ""))) (error-out "keystore id must be a non empty string."))) - (unless (memq '(pem pkcs11) - (knot-keystore-configuration-backend keystore)) - (error-out "backend must be one of: 'pem or 'pkcs11"))) + (unless (memq (knot-keystore-configuration-backend keystore) + '(pem pkcs11)) + (error-out "backend must be one of: 'pem or 'pkcs11"))) (define (verify-knot-policy-configuration policy) (unless (knot-policy-configuration? policy) @@ -288,7 +288,7 @@ (unless (and (string? id) (not (equal? id ""))) (error-out "acl id must be a non empty string.")) (unless (and (list? address) - (fold (lambda (x1 x2) (and (string? x1) (string? x2))) "" address)) + (every string? address)) (error-out "acl address must be a list of strings."))) (unless (boolean? (knot-acl-configuration-deny? acl)) (error-out "deny? must be #t or #f."))) diff --git a/gnu/services/linux.scm b/gnu/services/linux.scm index 1046a7e0c2..340b330030 100644 --- a/gnu/services/linux.scm +++ b/gnu/services/linux.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re> ;;; Copyright © 2020 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2021 raid5atemyhomework <raid5atemyhomework@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -150,7 +151,7 @@ representation." (shepherd-service (documentation "Load kernel modules.") (provision '(kernel-module-loader)) - (requirement '(file-systems)) + (requirement '()) (one-shot? #t) (modules `((srfi srfi-1) (srfi srfi-34) diff --git a/gnu/services/nfs.scm b/gnu/services/nfs.scm index 859097e788..277178c058 100644 --- a/gnu/services/nfs.scm +++ b/gnu/services/nfs.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2016 John Darrington <jmd@gnu.org> ;;; Copyright © 2018, 2019, 2020 Ricardo Wurmus <rekado@elephly.net> -;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -69,7 +69,7 @@ (rpcbind-configuration-rpcbind config)) (define rpcbind-command - #~(list (string-append #$rpcbind "/bin/rpcbind") "-f" + #~(list (string-append #$rpcbind "/sbin/rpcbind") "-f" #$@(if (rpcbind-configuration-warm-start? config) '("-w") '()))) (shepherd-service diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm index 4590709187..60611dc77d 100644 --- a/gnu/services/xorg.scm +++ b/gnu/services/xorg.scm @@ -45,6 +45,7 @@ #:use-module (gnu packages admin) #:use-module (gnu packages bash) #:use-module (gnu system shadow) + #:use-module (guix build-system trivial) #:use-module (guix gexp) #:use-module (guix store) #:use-module (guix packages) @@ -70,6 +71,7 @@ xorg-wrapper xorg-start-command xinitrc + xorg-server-service-type %default-slim-theme %default-slim-theme-name @@ -483,6 +485,41 @@ a `service-extension', as used by `set-xorg-configuration'." (xorg-configuration xorg-configuration)) config))))))) +(define (xorg-server-profile-service config) + ;; XXX: profile-service-type only accepts <package> objects. + (list + (package + (name "xorg-wrapper") + (version (package-version xorg-server)) + (source (xorg-wrapper config)) + (build-system trivial-build-system) + (arguments + '(#:modules ((guix build utils)) + #:builder + (begin + (use-modules (guix build utils)) + (let* ((source (assoc-ref %build-inputs "source")) + (out (assoc-ref %outputs "out")) + (bin (string-append out "/bin"))) + (mkdir-p bin) + (symlink source (string-append bin "/X")) + (symlink source (string-append bin "/Xorg")) + #t)))) + (home-page (package-home-page xorg-server)) + (synopsis (package-synopsis xorg-server)) + (description (package-description xorg-server)) + (license (package-license xorg-server))))) + +(define xorg-server-service-type + (service-type + (name 'xorg-server) + (extensions + (list (service-extension profile-service-type + xorg-server-profile-service))) + (default-value (xorg-configuration)) + (description "Add @command{X} to the system profile, to be used with +@command{sx} or @command{xinit}."))) + ;;; ;;; SLiM log-in manager. |