!QhvgabMQzwEQeWehhZ:lossy.network

NixOS Home Automation

515 Members
Declarative Home Automation and other Sidequests | https://wiki.nixos.org/wiki/Home_Assistant133 Servers

Load older messages


SenderMessageTime
20 Nov 2024
@hexa:lossy.network@hexa:lossy.network apyh: indeed, the module does not provide any option to pass a secrets file. Would probably do it with a tmpfiles rule to create a symlink from /var/lib/hass/secrets.yaml to where my secrets were decrypted at, e.g. /run/agenix/hass-secrets.yaml 12:12:09
@mjm:midna.devmjmthat’s exactly how I do it14:17:38
@hexa:lossy.network@hexa:lossy.networkfeel free to send a PR with an option for that14:54:34
@hexa:lossy.network@hexa:lossy.networksecretsFile14:54:41
@netpleb:matrix.orgnetpleb joined the room.23:38:31
@netpleb:matrix.orgnetpleb
In reply to @koen:procolix.com
Feb 28 21:35:12 frigate python3.11[36370]: OSError: libedgetpu.so.1.0: cannot open shared object file: No such file or directory
better late than never -- did you ever resolve this issue? I am getting the same error when trying to get the frigate nixos module working with coral usb edgetpu
23:45:50
@hexa:lossy.network@hexa:lossy.network
frigate/detectors/plugins/edgetpu_tfl.py
41:            edge_tpu_delegate = load_delegate("libedgetpu.so.1.0", device_config)
23:50:09
@hexa:lossy.network@hexa:lossy.network Is suspect you need to patch libedgetpu.so.1.0 with the absolute path to the library in nixpkgs 23:50:37
@netpleb:matrix.orgnetpleb
In reply to @hexa:lossy.network
Is suspect you need to patch libedgetpu.so.1.0 with the absolute path to the library in nixpkgs
uh oh, this is something I have never done before
23:51:14
@hexa:lossy.network@hexa:lossy.networkhm ok23:51:30
@netpleb:matrix.orgnetpleb but I am happy and willing to try! so you're saying the issue is likely not with frigate and that simply putting environment.systemPackages = [ "libedgetpu" ]; in the config is not enough? 23:52:34
@hexa:lossy.network@hexa:lossy.networkthat will only put ${libedgetpu.out}/bin intO PATH23:53:05
@hexa:lossy.network@hexa:lossy.network * that will only put ${libedgetpu.out}/bin into PATH23:53:07
@netpleb:matrix.orgnetpleb
In reply to @hexa:lossy.network
that will only put ${libedgetpu.out}/bin into PATH
sorry, I am dumb when it comes to these things, please bear with me. So do I not even need to have libedgetpu included in environment.systemPackages at all?
23:55:06
@hexa:lossy.network@hexa:lossy.networkload_delegate is a function provided by tensorflow that wants to load a shared library at runtime23:55:43
@hexa:lossy.network@hexa:lossy.networkbut since nixos does not store libraries in easily discoverable paths like /usr/lib or similar, we need some patching23:56:13
@netpleb:matrix.orgnetplebI see. That makes sense. So I need to apply the patch to frigate? (I'm using the nixos unstable module)23:57:32
@hexa:lossy.network@hexa:lossy.networkone minute23:57:51
@hexa:lossy.network@hexa:lossy.networkhttps://github.com/NixOS/nixpkgs/pull/35771723:59:41
@hexa:lossy.network@hexa:lossy.networkuntested23:59:48
21 Nov 2024
@netpleb:matrix.orgnetpleb
In reply to @hexa:lossy.network
https://github.com/NixOS/nixpkgs/pull/357717
whoa, you are amazing!!! ok I will test it and see what happens!
00:01:14
@netpleb:matrix.orgnetplebreally dumb question -- when you test something like this, what is you usual method? I figured I would just change my nixpkgs input from nixos-unstable over to that PR branch you just published. That pretty much what you do?00:02:30
@netpleb:matrix.orgnetplebsorry, maybe the better question is this: for home automation things, do you end up with multiple version of nixpkgs as inputs? Such as "nixpkgs-frigate" and "nixpkgs-home-assistant" so that you're able to bump along and pull in latest things?00:04:06
@hexa:lossy.network@hexa:lossy.networkI would probably override the package00:04:14
@hexa:lossy.network@hexa:lossy.networkhttps://search.nixos.org/options?channel=unstable&show=services.frigate.package&from=0&size=50&sort=relevance&type=packages&query=frigate.package00:04:47
@hexa:lossy.network@hexa:lossy.network so this option defaults to pkgs.frigate 00:04:52
@hexa:lossy.network@hexa:lossy.networkand you could in theory do the following00:04:59
@hexa:lossy.network@hexa:lossy.network
{ lib, pkgs, ... }:
{
  services.frigate.package = pkgs.frigate.overrideAttrs (oldAttrs: {
    patches = oldAttrs.patches or [ ] ++ [
      (substituteAll {
        src = ./libedgetpu.patch;
        libedgetpu = "${lib.getLib pkgs.libedgetpu}/lib/libedgetpu.so.1.0";
       })
    ];
  });
}
00:06:29
@hexa:lossy.network@hexa:lossy.networkand then drop the patch into the same directory00:06:47
@netpleb:matrix.orgnetpleb
In reply to @hexa:lossy.network
and then drop the patch into the same directory
ok, I will try that, thanks! I have never done this type of patching. I presume I download the patch file from your github PR branch?
00:08:36

Show newer messages


Back to Room ListRoom Version: 6