colmena/flake.nix

43 lines
1.1 KiB
Nix
Raw Normal View History

{
description = "A simple, stateless NixOS deployment tool modeled after NixOps.";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
utils.url = "github:numtide/flake-utils";
flake-compat = {
url = "github:edolstra/flake-compat";
flake = false;
};
};
outputs = { self, nixpkgs, utils, ... }: let
2021-09-20 07:03:39 +02:00
supportedSystems = utils.lib.defaultSystems;
in utils.lib.eachSystem supportedSystems (system: let
pkgs = import nixpkgs { inherit system; };
in rec {
# We still maintain the expression in a Nixpkgs-acceptable form
2021-09-20 07:03:39 +02:00
packages.colmena = import ./default.nix { inherit pkgs; };
defaultPackage = self.packages.${system}.colmena;
defaultApp = self.apps.${system}.colmena;
apps.colmena = {
type = "app";
program = "${defaultPackage}/bin/colmena";
};
devShell = pkgs.mkShell {
inputsFrom = [ defaultPackage ];
2021-06-29 11:04:54 +02:00
shellHook = ''
export NIX_PATH=nixpkgs=${pkgs.path}
'';
};
2021-09-20 07:03:39 +02:00
}) // {
overlay = final: prev: {
colmena = import ./default.nix {
pkgs = final;
};
};
};
}