-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflake.nix
40 lines (32 loc) · 1.02 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
{
inputs = {
nixpkgs.url = "nixpkgs/nixos-24.11";
# These match `moduleName` in the NixOS modules.
portier-broker = {
url = "github:portier/portier-broker/stable";
inputs.nixpkgs.follows = "nixpkgs";
};
portier-broker-testing = {
url = "github:portier/portier-broker/main";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { nixpkgs, ... } @ flakeInputs: rec {
nixosConfigurations.public-portier = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
# Make flakeInputs available in module args.
{ _module.args = { inherit flakeInputs; }; }
# Main server configuration.
./server-config/configuration.nix
];
};
# For easy `nix build`.
packages.x86_64-linux.default = nixosConfigurations.public-portier.config.system.build.toplevel;
devShells = builtins.mapAttrs (system: pkgs: {
default = pkgs.mkShellNoCC {
packages = [ pkgs.nixos-rebuild ];
};
}) nixpkgs.legacyPackages;
};
}