diff options
| author | Fabian Montero <fabian@posixlycorrect.com> | 2026-02-03 15:12:59 -0600 |
|---|---|---|
| committer | Fabian Montero <fabian@posixlycorrect.com> | 2026-02-03 15:12:59 -0600 |
| commit | 4a822c48da5a3aa4550fd0fad2697fd023c1810a (patch) | |
| tree | 3ad3d1fc31c545daf0d1c221c5cefba83c6cea04 /modules/socialpredict/options.nix | |
| parent | e44c6337d4557c9377b562e3687d24ef5e236974 (diff) | |
| parent | 0f6a8aa22d9b554c211a9d77bbf4fefdcabc20d1 (diff) | |
Merge commit '974154ce2da0b60bdff5ae3c57e0490db58d9f0e'
Diffstat (limited to 'modules/socialpredict/options.nix')
| -rw-r--r-- | modules/socialpredict/options.nix | 78 |
1 files changed, 78 insertions, 0 deletions
diff --git a/modules/socialpredict/options.nix b/modules/socialpredict/options.nix new file mode 100644 index 0000000..bb2ad5e --- /dev/null +++ b/modules/socialpredict/options.nix @@ -0,0 +1,78 @@ +{ + config, + doctrine, + lib, + modulesPath, + pkgs, + ... +}: +with lib.types; let + inherit (pkgs.${doctrine.prefix}) socialpredict; +in { + sys = { + frontend = lib.mkOption { + type = package; + default = socialpredict.frontend; + defaultText = "pkgs.\${doctrine.prefix}.frontend"; + description = "socialpredict frontend package"; + }; + + backend = lib.mkOption { + type = package; + default = socialpredict.backend; + defaultText = "pkgs.\${doctrine.prefix}.backend"; + description = "socialpredict backend package"; + }; + + package = lib.mkOption { + type = package; + default = pkgs.${doctrine.prefix}.socialpredict; + defaultText = "pkgs.\${doctrine.prefix}.socialpredict"; + description = "socialpredict package"; + }; + + database = lib.mkOption { + type = str; + default = "socialpredict"; + description = "database name"; + }; + + user = lib.mkOption { + type = str; + default = "socialpredict"; + description = "user that will run the backend"; + }; + + group = lib.mkOption { + type = str; + default = "socialpredict"; + description = "group that will run the backend"; + }; + + backendPort = lib.mkOption { + type = port; + description = "backend port"; + }; + + initialAdminPassword = lib.mkOption { + type = str; + default = "change-me"; + description = "initial password of the 'admin' user"; + }; + + domain = lib.mkOption { + type = nullOr str; + default = null; + description = "domain host"; + }; + + nginx = lib.mkOption { + type = submodule ( + lib.recursiveUpdate (import "${modulesPath}/services/web-servers/nginx/vhost-options.nix" {inherit config lib;}) {} + ); + + default = {}; + description = "extra nginx virtual host config"; + }; + }; +} |
