bluetooth: dont persist /var/lib/bluetooth

This commit is contained in:
2023-01-07 08:08:29 +00:00
parent 9e902c8eb2
commit 85a2fbc38a
3 changed files with 5 additions and 1 deletions

View File

@@ -1,6 +1,10 @@
{ lib, pkgs, ... }: { lib, pkgs, ... }:
{ {
# optionally: persist handshakes. can be useful when debugging, but might disrupt other keys
# sane.persist.sys.plaintext = [ "/var/lib/bluetooth" ];
sane.fs."/var/lib/bluetooth".generated.acl.mode = "0700";
sane.fs."/var/lib/bluetooth/.secrets.stamp" = { sane.fs."/var/lib/bluetooth/.secrets.stamp" = {
wantedBeforeBy = [ "bluetooth.service" ]; wantedBeforeBy = [ "bluetooth.service" ];
# XXX: install-bluetooth uses sed, but that's part of the default systemd unit path, it seems # XXX: install-bluetooth uses sed, but that's part of the default systemd unit path, it seems

View File

@@ -23,7 +23,6 @@
"/var/backup" # for e.g. postgres dumps "/var/backup" # for e.g. postgres dumps
# TODO: move elsewhere # TODO: move elsewhere
"/var/lib/alsa" # preserve output levels, default devices "/var/lib/alsa" # preserve output levels, default devices
"/var/lib/bluetooth" # preserve bluetooth handshakes
"/var/lib/colord" # preserve color calibrations (?) "/var/lib/colord" # preserve color calibrations (?)
"/var/lib/machines" # maybe not needed, but would be painful to add a VM and forget. "/var/lib/machines" # maybe not needed, but would be painful to add a VM and forget.
]; ];

View File

@@ -25,4 +25,5 @@ do
condir="$destdir/$mac" condir="$destdir/$mac"
test -d "$condir" || mkdir "$condir" || test -d "$condir" test -d "$condir" || mkdir "$condir" || test -d "$condir"
ln -sf --no-dereference "$srcdir/$f" "$condir/info" ln -sf --no-dereference "$srcdir/$f" "$condir/info"
touch "$condir/attributes"
done done