X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=modules%2Fprivate%2Fenvironment.nix;h=82e39817190ac31cf6efccb979cba58824366a43;hb=6338573a8a4b416d5bce384dac712197f90637dc;hp=01ab967bf53551d8cd7eae627c98dd6a1ca4e158;hpb=d3452fc59b9839846225fd254926c64a9c71f071;p=perso%2FImmae%2FConfig%2FNix.git diff --git a/modules/private/environment.nix b/modules/private/environment.nix index 01ab967..82e3981 100644 --- a/modules/private/environment.nix +++ b/modules/private/environment.nix @@ -108,6 +108,19 @@ let }; }; }; + smtpOptions = { + host = mkOption { description = "Host to access SMTP"; type = str; }; + port = mkOption { description = "Port to access SMTP"; type = str; }; + }; + mkSmtpOptions = name: mkOption { + description = "${name} smtp configuration"; + type = submodule { + options = smtpOptions // { + email = mkOption { description = "${name} email"; type = str; }; + password = mkOption { description = "SMTP password of the ${name} user"; type = str; }; + }; + }; + }; hostEnv = submodule { options = { fqdn = mkOption { @@ -258,6 +271,10 @@ in }; }; }; + smtp = mkOption { + type = submodule { options = smtpOptions; }; + description = "SMTP configuration"; + }; ldap = mkOption { description = '' LDAP server configuration @@ -450,6 +467,7 @@ in type = attrsOf (submodule { options = { keep = mkOption { type = int; description = "Number of backups to keep"; }; + check_command = mkOption { type = str; description = "command to check if backup needs to be done"; default = "backup"; }; login = mkOption { type = str; description = "Login to connect to host"; }; port = mkOption { type = str; default = "22"; description = "Port to connect to host"; }; host = mkOption { type = str; description = "Host to connect to"; }; @@ -650,6 +668,7 @@ in user_attrs = mkOption { type = str; description = "User attribute mapping in LDAP"; }; iterate_attrs = mkOption { type = str; description = "User attribute mapping for listing in LDAP"; }; iterate_filter = mkOption { type = str; description = "User attribute filter for listing in LDAP"; }; + postfix_mailbox_filter = mkOption { type = str; description = "Postfix filter to get mailboxes"; }; }; }; }; @@ -698,6 +717,28 @@ in }; }); }; + sympa = mkOption { + description = "Sympa configuration"; + type = submodule { + options = { + listmasters = mkOption { + type = listOf str; + description = "Listmasters"; + }; + postgresql = mkPsqlOptions "Sympa"; + data_sources = mkOption { + type = attrsOf str; + default = {}; + description = "Data sources to make available to sympa"; + }; + scenari = mkOption { + type = attrsOf str; + default = {}; + description = "Scenari to make available to sympa"; + }; + }; + }; + }; }; }; }; @@ -799,6 +840,7 @@ in description = "Tools configurations"; type = submodule { options = { + contact = mkOption { type = str; description = "Contact e-mail address"; }; davical = mkOption { description = "Davical configuration"; type = submodule { @@ -819,6 +861,15 @@ in }; }; }; + dmarc_reports = mkOption { + description = "DMARC reports configuration"; + type = submodule { + options = { + mysql = mkMysqlOptions "DMARC" {}; + anonymous_key = mkOption { type = str; description = "Anonymous hashing key"; }; + }; + }; + }; etherpad-lite = mkOption { description = "Etherpad configuration"; type = submodule { @@ -827,6 +878,7 @@ in ldap = mkLdapOptions "Etherpad" { group_filter = mkOption { type = str; description = "Filter for groups"; }; }; + adminPassword = mkOption { type = str; description = "Admin password for mypads / admin"; }; session_key = mkOption { type = str; description = "Session key"; }; api_key = mkOption { type = str; description = "API key"; }; redirects = mkOption { type = str; description = "Redirects for apache"; }; @@ -1012,6 +1064,20 @@ in }; }; }; + webhooks = mkOption { + type = attrsOf str; + description = "Mapping 'name'.php => script for webhooks"; + }; + commento = mkOption { + description = "Commento configuration"; + type = submodule { + options = { + listenPort = mkOption { type = port; description = "Port to listen to"; }; + postgresql = mkPsqlOptions "Commento"; + smtp = mkSmtpOptions "Commento"; + }; + }; + }; ympd = mkOption { description = "Ympd configuration"; type = submodule { @@ -1047,6 +1113,23 @@ in description = "Websites configurations"; type = submodule { options = { + immae = mkOption { + description = "Immae configuration by environment"; + type = submodule { + options = { + temp = mkOption { + description = "Temp configuration"; + type = submodule { + options = { + ldap = mkLdapOptions "Immae temp" { + filter = mkOption { type = str; description = "Filter for user access"; }; + }; + }; + }; + }; + }; + }; + }; isabelle = mkOption { description = "Isabelle configurations by environment"; type =