2020-07-06 07:44:11 +00:00
|
|
|
{
|
|
|
|
description = "Integrates sops into nixos";
|
2020-11-08 13:23:58 +00:00
|
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
2020-07-06 07:44:11 +00:00
|
|
|
outputs = { self, nixpkgs }: let
|
|
|
|
systems = [
|
|
|
|
"x86_64-linux"
|
|
|
|
"i686-linux"
|
|
|
|
"x86_64-darwin"
|
2021-08-28 05:04:18 +00:00
|
|
|
"aarch64-darwin"
|
2020-07-06 07:44:11 +00:00
|
|
|
"aarch64-linux"
|
|
|
|
"armv6l-linux"
|
|
|
|
"armv7l-linux"
|
|
|
|
];
|
|
|
|
forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
|
|
|
|
in {
|
2021-02-06 16:47:44 +00:00
|
|
|
overlay = final: prev:
|
|
|
|
let
|
|
|
|
localPkgs = import ./default.nix { pkgs = final; };
|
|
|
|
in {
|
2021-08-27 18:17:39 +00:00
|
|
|
inherit (localPkgs) sops-install-secrets sops-init-gpg-key sops-pgp-hook sops-import-keys-hook sops-ssh-to-age;
|
2021-02-01 11:12:20 +00:00
|
|
|
# backward compatibility
|
|
|
|
inherit (prev) ssh-to-pgp;
|
2021-02-06 16:47:44 +00:00
|
|
|
};
|
2020-07-06 07:44:11 +00:00
|
|
|
nixosModules.sops = import ./modules/sops;
|
2021-03-06 09:22:39 +00:00
|
|
|
nixosModule = self.nixosModules.sops;
|
2021-01-26 12:25:51 +00:00
|
|
|
packages = forAllSystems (system: import ./default.nix {
|
|
|
|
pkgs = import nixpkgs { inherit system; };
|
|
|
|
});
|
2020-07-06 07:44:11 +00:00
|
|
|
defaultPackage = forAllSystems (system: self.packages.${system}.sops-init-gpg-key);
|
|
|
|
};
|
|
|
|
}
|