modules/usteer: init

This adds the usteer daemon service for Liminix.

Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
This commit is contained in:
Raito Bezarius 2025-02-06 01:36:23 +01:00 committed by sinavir
parent be143d1a13
commit 27635fbe92
No known key found for this signature in database
2 changed files with 44 additions and 0 deletions

View file

@ -0,0 +1,26 @@
## usteer
## ==============
##
## usteer is a band-steering daemon for hostapd.
## this helps you optimize the roaming behavior of wireless clients (STAs) in an ESS
## consisting of multiple BSS / APs.
## you want this as soon as you are deploying Liminix on >1 APs that are close to each other.
{ lib, pkgs, ... }:
let
inherit (lib) mkOption types;
inherit (pkgs) liminix;
in {
options.system.service.usteer = mkOption {
type = liminix.lib.types.serviceDefn;
};
config = {
system.service.usteer = pkgs.liminix.callService ./usteer.nix {
ifname = mkOption {
type = types.str;
description = "interface name on which to connect to other usteer instances";
};
};
};
}

18
modules/usteer/usteer.nix Normal file
View file

@ -0,0 +1,18 @@
{
liminix
, lib
, usteer
}:
{ ifname }:
let
inherit (liminix.services) longrun;
name = "usteerd";
in
longrun {
# Does it need to be unique?
inherit name;
run = ''
mkdir -p /run/usteerd
${usteer}/bin/usteerd -s -v -i ${ifname}
'';
}