2021-05-30 15:32:10 +00:00
|
|
|
{ config, lib, name, ... }:
|
|
|
|
{
|
|
|
|
options = {
|
2024-08-24 20:05:37 +00:00
|
|
|
dataPath = lib.mkOption {
|
|
|
|
type = lib.types.path;
|
2021-05-30 15:32:10 +00:00
|
|
|
default = "/var/lib/pantalaimon-${name}";
|
|
|
|
description = ''
|
|
|
|
The directory where `pantalaimon` should store its state such as the database file.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
logLevel = lib.mkOption {
|
|
|
|
type = lib.types.enum [ "info" "warning" "error" "debug" ];
|
2021-05-30 15:32:10 +00:00
|
|
|
default = "warning";
|
|
|
|
description = ''
|
|
|
|
Set the log level of the daemon.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
homeserver = lib.mkOption {
|
|
|
|
type = lib.types.str;
|
2021-05-30 15:32:10 +00:00
|
|
|
example = "https://matrix.org";
|
|
|
|
description = ''
|
|
|
|
The URI of the homeserver that the `pantalaimon` proxy should
|
|
|
|
forward requests to, without the matrix API path but including
|
|
|
|
the http(s) schema.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
ssl = lib.mkOption {
|
|
|
|
type = lib.types.bool;
|
2021-05-30 15:32:10 +00:00
|
|
|
default = true;
|
|
|
|
description = ''
|
|
|
|
Whether or not SSL verification should be enabled for outgoing
|
|
|
|
connections to the homeserver.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
listenAddress = lib.mkOption {
|
|
|
|
type = lib.types.str;
|
2021-05-30 15:32:10 +00:00
|
|
|
default = "localhost";
|
|
|
|
description = ''
|
|
|
|
The address where the daemon will listen to client connections
|
|
|
|
for this homeserver.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
listenPort = lib.mkOption {
|
|
|
|
type = lib.types.port;
|
2021-05-30 15:32:10 +00:00
|
|
|
default = 8009;
|
|
|
|
description = ''
|
|
|
|
The port where the daemon will listen to client connections for
|
|
|
|
this homeserver. Note that the listen address/port combination
|
2024-08-24 20:05:37 +00:00
|
|
|
needs to be lib.unique between different homeservers.
|
2021-05-30 15:32:10 +00:00
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:37 +00:00
|
|
|
extraSettings = lib.mkOption {
|
|
|
|
type = lib.types.attrs;
|
2021-05-30 15:32:10 +00:00
|
|
|
default = { };
|
|
|
|
description = ''
|
|
|
|
Extra configuration options. See
|
|
|
|
[pantalaimon(5)](https://github.com/matrix-org/pantalaimon/blob/master/docs/man/pantalaimon.5.md)
|
|
|
|
for available options.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|