2023-09-04 12:45:13 -04:00
|
|
|
{
|
|
|
|
description = "Constellation";
|
|
|
|
|
|
|
|
inputs = {
|
|
|
|
nixpkgsUnstable = {
|
2023-11-09 14:17:14 -05:00
|
|
|
url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
2023-09-04 12:45:13 -04:00
|
|
|
};
|
|
|
|
flake-utils = {
|
|
|
|
url = "github:numtide/flake-utils";
|
|
|
|
};
|
2024-01-16 05:07:15 -05:00
|
|
|
uplosi = {
|
2024-01-26 10:37:10 -05:00
|
|
|
url = "github:edgelesssys/uplosi";
|
2024-01-16 05:07:15 -05:00
|
|
|
};
|
2023-09-04 12:45:13 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
outputs =
|
|
|
|
{ self
|
|
|
|
, nixpkgsUnstable
|
|
|
|
, flake-utils
|
2024-01-16 05:07:15 -05:00
|
|
|
, uplosi
|
2023-09-04 12:45:13 -04:00
|
|
|
}:
|
|
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
|
|
let
|
|
|
|
pkgsUnstable = import nixpkgsUnstable { inherit system; };
|
|
|
|
|
2023-11-23 11:24:54 -05:00
|
|
|
callPackage = pkgsUnstable.callPackage;
|
|
|
|
|
2023-10-04 04:50:42 -04:00
|
|
|
mkosiDev = (pkgsUnstable.mkosi.overrideAttrs (oldAttrs: rec {
|
2023-12-11 07:49:10 -05:00
|
|
|
# TODO(malt3): remove patch once merged and released upstream (systemd/mkosi#2163)
|
|
|
|
src = pkgsUnstable.fetchFromGitHub {
|
|
|
|
owner = "systemd";
|
|
|
|
repo = "mkosi";
|
2023-12-14 10:26:51 -05:00
|
|
|
rev = "abf22cdc6ccb13f2cd84679ede77231455ec6813";
|
|
|
|
hash = "sha256-njtYWSXSLMcn6AtGfAeL/ncZQ6g+Vgpe7EaKLkzAOl4=";
|
2023-12-11 07:49:10 -05:00
|
|
|
};
|
2023-10-04 04:50:42 -04:00
|
|
|
propagatedBuildInputs = oldAttrs.propagatedBuildInputs ++ (with pkgsUnstable; [
|
2023-09-04 12:45:13 -04:00
|
|
|
# package management
|
|
|
|
dnf5
|
|
|
|
rpm
|
|
|
|
|
|
|
|
# filesystem tools
|
|
|
|
squashfsTools # mksquashfs
|
|
|
|
dosfstools # mkfs.vfat
|
|
|
|
mtools # mcopy
|
|
|
|
cryptsetup # dm-verity
|
|
|
|
util-linux # flock
|
|
|
|
kmod # depmod
|
2023-12-11 07:49:10 -05:00
|
|
|
cpio # cpio
|
|
|
|
zstd # zstd
|
|
|
|
xz # xz
|
2023-09-04 12:45:13 -04:00
|
|
|
]);
|
|
|
|
}));
|
|
|
|
|
2024-01-16 05:07:15 -05:00
|
|
|
uplosiDev = uplosi.outputs.packages."${system}".uplosi;
|
2024-01-04 10:34:15 -05:00
|
|
|
|
2023-10-04 07:17:01 -04:00
|
|
|
openssl-static = pkgsUnstable.openssl.override { static = true; };
|
|
|
|
|
2023-09-04 12:45:13 -04:00
|
|
|
in
|
|
|
|
{
|
|
|
|
packages.mkosi = mkosiDev;
|
|
|
|
|
2024-01-04 10:34:15 -05:00
|
|
|
packages.uplosi = uplosiDev;
|
|
|
|
|
2023-11-23 11:24:54 -05:00
|
|
|
packages.openssl = callPackage ./nix/cc/openssl.nix { pkgs = pkgsUnstable; };
|
|
|
|
|
|
|
|
packages.cryptsetup = callPackage ./nix/cc/cryptsetup.nix { pkgs = pkgsUnstable; pkgsLinux = import nixpkgsUnstable { system = "x86_64-linux"; }; };
|
|
|
|
|
|
|
|
packages.libvirt = callPackage ./nix/cc/libvirt.nix { pkgs = pkgsUnstable; pkgsLinux = import nixpkgsUnstable { system = "x86_64-linux"; }; };
|
2023-10-04 07:17:01 -04:00
|
|
|
|
2023-11-28 04:52:37 -05:00
|
|
|
packages.libvirtd_base = callPackage ./nix/container/libvirtd_base.nix { pkgs = pkgsUnstable; pkgsLinux = import nixpkgsUnstable { system = "x86_64-linux"; }; };
|
|
|
|
|
2023-10-16 10:45:36 -04:00
|
|
|
packages.awscli2 = pkgsUnstable.awscli2;
|
|
|
|
|
2023-11-03 06:41:45 -04:00
|
|
|
packages.bazel_6 = pkgsUnstable.bazel_6;
|
|
|
|
|
2023-10-16 10:45:36 -04:00
|
|
|
packages.createrepo_c = pkgsUnstable.createrepo_c;
|
|
|
|
|
|
|
|
packages.dnf5 = pkgsUnstable.dnf5;
|
|
|
|
|
2023-09-04 12:45:13 -04:00
|
|
|
devShells.default = import ./nix/shells/default.nix { pkgs = pkgsUnstable; };
|
|
|
|
|
|
|
|
formatter = nixpkgsUnstable.legacyPackages.${system}.nixpkgs-fmt;
|
|
|
|
});
|
|
|
|
}
|