Added live disk flake
This commit is contained in:
@@ -4,7 +4,10 @@
|
||||
inputs = {
|
||||
nixpkgs.url = "nixpkgs/nixos-21.05";
|
||||
|
||||
fudo-home.url = "git+https://git.fudo.org/fudo-nix/home.git";
|
||||
fudo-home = {
|
||||
url = "git+https://git.fudo.org/fudo-nix/home.git";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
# This MUST be a clean git repo, because we use the timestamp.
|
||||
fudo-entities = {
|
||||
@@ -25,6 +28,8 @@
|
||||
chute.url = "git+https://git.fudo.org/chute/chute.git?ref=stable";
|
||||
|
||||
chuteUnstable.url = "git+https://git.fudo.org/chute/chute.git?ref=master";
|
||||
|
||||
nixpkgsUnstable.url = "nixpkgs/nixos-unstable";
|
||||
};
|
||||
|
||||
outputs = { self,
|
||||
@@ -36,6 +41,7 @@
|
||||
fudo-secrets,
|
||||
chute,
|
||||
chuteUnstable,
|
||||
nixpkgsUnstable,
|
||||
... } @ inputs:
|
||||
with nixpkgs.lib;
|
||||
let
|
||||
@@ -45,7 +51,19 @@
|
||||
|
||||
fudo-networks = fudo-entities.entities.networks;
|
||||
|
||||
pkgs-for = arch: import nixpkgs {
|
||||
unstable-for = arch: import nixpkgsUnstable {
|
||||
system = arch;
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
permittedInsecurePackages = [
|
||||
"openssh-with-gssapi-8.4p1"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
pkgs-for = arch: let
|
||||
unstable = unstable-for arch;
|
||||
in import nixpkgs {
|
||||
system = arch;
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
@@ -60,6 +78,9 @@
|
||||
chute = chute.packages.${arch}.chute;
|
||||
chuteUnstable = chuteUnstable.packages.${arch}.chute;
|
||||
})
|
||||
(final: prev: {
|
||||
nyxt = unstable.nyxt;
|
||||
})
|
||||
];
|
||||
};
|
||||
|
||||
@@ -91,7 +112,9 @@
|
||||
(config-dir + /site-config/${hostOpts.site}.nix)
|
||||
];
|
||||
|
||||
config = {
|
||||
config = let
|
||||
pkgs = pkgs-for hostOpts.arch;
|
||||
in {
|
||||
instance = let
|
||||
build-seed = builtins.readFile
|
||||
config.fudo.secrets.files.build-seed;
|
||||
@@ -99,14 +122,24 @@
|
||||
inherit hostname build-timestamp build-seed;
|
||||
};
|
||||
|
||||
nix.registry = {
|
||||
fudo-nixos.flake = self;
|
||||
fudo-entities.flake = fudo-entities;
|
||||
fudo-lib.flake = fudo-lib;
|
||||
fudo-pkgs.flake = fudo-pkgs;
|
||||
environment.etc.nixos-live.source = ./.;
|
||||
|
||||
nix = {
|
||||
registry = {
|
||||
nixpkgs.flake = nixpkgs;
|
||||
fudo-nixos.flake = self;
|
||||
fudo-entities.flake = fudo-entities;
|
||||
fudo-lib.flake = fudo-lib;
|
||||
fudo-pkgs.flake = fudo-pkgs;
|
||||
};
|
||||
nixPath = let
|
||||
lib = nixpkgs.lib;
|
||||
in lib.mkDefault (lib.mkBefore [
|
||||
"nixpkgs=${nixpkgs}"
|
||||
]);
|
||||
};
|
||||
|
||||
nixpkgs.pkgs = pkgs-for hostOpts.arch;
|
||||
nixpkgs.pkgs = pkgs;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user