-
Notifications
You must be signed in to change notification settings - Fork 907
/
flake.nix
64 lines (58 loc) · 1.57 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
{
description = "Core Lightning (CLN): A specification compliant Lightning Network implementation in C";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
flake-parts.url = "github:hercules-ci/flake-parts";
crane.url = "github:ipetkov/crane";
treefmt-nix.url = "github:numtide/treefmt-nix";
advisory-db = {
url = "github:rustsec/advisory-db";
flake = false;
};
};
outputs =
inputs@{
self,
nixpkgs,
flake-parts,
...
}:
flake-parts.lib.mkFlake { inherit inputs; } {
systems = nixpkgs.lib.systems.flakeExposed;
imports = [
inputs.treefmt-nix.flakeModule
./nix/pkgs/flake-module.nix
./nix/checks/flake-module.nix
./nix/shells.nix
./nix/treefmt.nix
];
perSystem =
{
config,
pkgs,
self',
system,
...
}:
{
_module.args.pkgs = import inputs.nixpkgs {
inherit system;
overlays = [ (final: prev: { craneLib = (inputs.crane.mkLib pkgs); }) ];
};
apps = {
lightningd = {
program = "${self'.packages.cln}/bin/lightningd";
};
lightning-cli = {
program = "${self'.packages.cln}/bin/lightning-cli";
};
lightning-hsmtool = {
program = "${self'.packages.cln}/bin/lightning-hsmtool";
};
reckless = {
program = "${self'.packages.cln}/bin/reckless";
};
};
};
};
}