refactor(pkgs): Use packagesFromDirectoryRecursive
This commit is contained in:
parent
cd012e86ba
commit
e2012ebc9a
8 changed files with 9 additions and 20 deletions
26
pkgs/packages/crowdsec-firewall-bouncer.nix
Normal file
26
pkgs/packages/crowdsec-firewall-bouncer.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
lib,
|
||||
sources,
|
||||
buildGoModule,
|
||||
envsubst,
|
||||
coreutils,
|
||||
}:
|
||||
let
|
||||
envsubstBin = lib.getExe envsubst;
|
||||
in
|
||||
buildGoModule {
|
||||
inherit (sources.crowdsec-firewall-bouncer) pname version src;
|
||||
|
||||
vendorHash = "sha256-SbpclloBgd9vffC0lBduGRqPOqmzQ0J91/KeDHCh0jo=";
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/lib/systemd/system
|
||||
|
||||
CFG=/var/lib/crowdsec/config BIN=$out/bin/cs-firewall-bouncer ${envsubstBin} \
|
||||
-i ./config/crowdsec-firewall-bouncer.service \
|
||||
-o $out/lib/systemd/system/crowdsec-firewall-bouncer.service
|
||||
|
||||
substituteInPlace $out/lib/systemd/system/crowdsec-firewall-bouncer.service \
|
||||
--replace-fail /bin/sleep ${coreutils}/bin/sleep
|
||||
'';
|
||||
}
|
1
pkgs/packages/crowdsec-hub.nix
Normal file
1
pkgs/packages/crowdsec-hub.nix
Normal file
|
@ -0,0 +1 @@
|
|||
{ sources }: sources.crowdsec-hub.src
|
Loading…
Add table
Add a link
Reference in a new issue