19 lines
739 B
Nix
19 lines
739 B
Nix
{ self, config, lib, registry, ... }:
|
|
{
|
|
TLMS.gnuradio = {
|
|
enable = true;
|
|
} // registry.gnuradio;
|
|
|
|
# find all the servers with data-accumulator configured
|
|
TLMS.telegramDecoder = let
|
|
registries = builtins.attrValues (builtins.mapAttrs (name: value: value.specialArgs.registry) self.unevaluatedNixosConfigurations);
|
|
filteredDataHoarders = builtins.filter (other: other ? port-data_accumulator) registries;
|
|
urlFromRegistry = other: "http://${other.wgAddr4}:${toString other.port-data_accumulator.port}";
|
|
in {
|
|
enable = true;
|
|
server = builtins.map urlFromRegistry filteredDataHoarders;
|
|
configFile = registry.telegramDecoderConfig;
|
|
authTokenFile = config.sops.secrets.telegram-decoder-token.path;
|
|
};
|
|
}
|