2022-12-03 11:05:09 +00:00
|
|
|
{ lib, pkgs, ... }:
|
|
|
|
|
|
|
|
{
|
2023-01-07 11:31:35 +00:00
|
|
|
# persist external pairings by default
|
|
|
|
sane.persist.sys.plaintext = [ "/var/lib/bluetooth" ];
|
2023-01-07 08:08:29 +00:00
|
|
|
|
|
|
|
sane.fs."/var/lib/bluetooth".generated.acl.mode = "0700";
|
2023-01-07 03:43:28 +00:00
|
|
|
sane.fs."/var/lib/bluetooth/.secrets.stamp" = {
|
|
|
|
wantedBeforeBy = [ "bluetooth.service" ];
|
|
|
|
# XXX: install-bluetooth uses sed, but that's part of the default systemd unit path, it seems
|
|
|
|
generated.script.script = builtins.readFile ../../scripts/install-bluetooth + ''
|
|
|
|
touch "/var/lib/bluetooth/.secrets.stamp"
|
|
|
|
'';
|
|
|
|
generated.script.scriptArgs = [ "/run/secrets/bt" ];
|
|
|
|
};
|
2022-12-03 11:05:09 +00:00
|
|
|
}
|