File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed
nixos/modules/services/networking Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change 143143 restartTriggers = [ cfg . unifiPackage cfg . mongodbPackage ] ;
144144
145145 serviceConfig = {
146- Type = "simple " ;
146+ Type = "notify " ;
147147 ExecStart = "${ cmd } start" ;
148148 ExecStop = "${ cmd } stop" ;
149- Restart = "on-failure " ;
149+ Restart = "always " ;
150150 TimeoutSec = "5min" ;
151151 User = "unifi" ;
152152 UMask = "0077" ;
Original file line number Diff line number Diff line change 44 dpkg ,
55 fetchurl ,
66 nixosTests ,
7+ systemd ,
78} :
89
910stdenv . mkDerivation rec {
@@ -28,6 +29,18 @@ stdenv.mkDerivation rec {
2829 runHook postInstall
2930 '' ;
3031
32+ postInstall =
33+ if stdenv . hostPlatform . system == "x86_64-linux" then
34+ ''
35+ patchelf --add-needed "${ systemd } /lib/libsystemd.so.0" "$out/lib/native/Linux/x86_64/libubnt_sdnotify_jni.so"
36+ ''
37+ else if stdenv . hostPlatform . system == "aarch64-linux" then
38+ ''
39+ patchelf --add-needed "${ systemd } /lib/libsystemd.so.0" "$out/lib/native/Linux/aarch64/libubnt_sdnotify_jni.so"
40+ ''
41+ else
42+ null ;
43+
3144 passthru . tests = {
3245 unifi = nixosTests . unifi ;
3346 } ;
You can’t perform that action at this time.
0 commit comments