WIP for weblate service in guix
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

86 lines
2.4 KiB

;; Base system
(use-modules (gnu packages base))
(use-modules (gnu bootloader))
(use-modules (gnu bootloader grub))
(use-modules (gnu system file-systems))
(use-modules (guix packages))
;; Helpers
(use-modules (gnu packages curl))
(use-modules (gnu packages wget))
(use-modules (gnu packages python))
(use-modules (gnu packages gtk))
(use-modules (gnu packages glib))
(use-modules (gnu packages version-control))
;; Services (ssh, dhcp)
(use-modules (gnu services ssh))
(use-modules (gnu services networking))
(use-modules (gnu) (gnu system nss))
(use-modules (weblate))
(use-modules (weblate-service))
(use-modules (gnu services web))
(use-modules (gnu packages web))
(use-modules (gnu packages databases))
(use-modules (gnu services databases))
(use-package-modules databases geo)
(use-modules (gnu packages php))
(use-modules (gnu packages certs))
(use-modules (guix utils))
(define weblate-user
(name "weblate")
(group "users")
(supplementary-groups '("netdev"))
(home-directory "/var/lib/weblate")))
(define (weblate/settings.py database-user website-url)
(local-file "settings.py"))
(host-name "weblate")
(timezone "Europe/Rome")
(locale "en_US.utf8")
(locale-libcs (list glibc-2.28 (canonical-package glibc)))
(bootloader (bootloader-configuration (bootloader grub-bootloader)))
(file-systems %base-file-systems)
(cons* weblate-user
pango cairo glib gobject-introspection git
(service dhcp-client-service-type)
;; Weblate
(service redis-service-type)
(service weblate-service-type
(settings-file (local-file "settings.py"))
(user "weblate")
(group "nginx")
(listen '(""))
(uwsgi-listen "")
(root "/var/lib/weblate")))
(service postgresql-service-type ;postgre
(postgresql postgresql)
(port 5431)
(data-directory "/srv/pgdata-weblate")
(plain-file "pg_hba.conf"
local all all trust
host all all trust
host all all ::1/128 trust"))))))
;; Allow resolution of '.local' host names with mDNS.
(name-service-switch %mdns-host-lookup-nss))