matt1432
f8dd9f7891
All checks were successful
Discord / discord commits (push) Has been skipped
Flake Inputs: • Updated input 'astal': 'github:Aylur/astal/5ae0a9e' (2024-09-21) → 'github:Aylur/astal/8cab7d0' (2024-09-22) • Updated input 'home-manager': 'github:nix-community/home-manager/14929f7' (2024-09-21) → 'github:nix-community/home-manager/04213d1' (2024-09-22) • Updated input 'hyprland': 'git+https://github.com/hyprwm/Hyprland?ref=refs/heads/main&rev=b248d59&submodules=1' (2024-09-18) → 'git+https://github.com/hyprwm/Hyprland?ref=refs/heads/main&rev=e5ff19a&submodules=1' (2024-09-22) • Updated input 'jovian': 'github:Jovian-Experiments/Jovian-NixOS/faf4c74' (2024-09-21) → 'github:Jovian-Experiments/Jovian-NixOS/d71bcb4' (2024-09-22) • Updated input 'nix-gaming': 'github:fufexan/nix-gaming/7ea77f2' (2024-09-20) → 'github:fufexan/nix-gaming/43a085b' (2024-09-22) • Updated input 'nix-index-db': 'github:Mic92/nix-index-database/c1b0fa0' (2024-09-16) → 'github:Mic92/nix-index-database/c7515c2' (2024-09-22) • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/eca2693' (2024-09-21) → 'github:NixOS/nixpkgs/c04d565' (2024-09-19) • Updated input 'nixpkgs-wayland': 'github:nix-community/nixpkgs-wayland/ff23ca1' (2024-09-21) → 'github:nix-community/nixpkgs-wayland/a1318d7' (2024-09-22) Docker Images: • nextcloud fpm: sha256:74e016552a6f908fa3700c0dfa3757fb20f8ff2a630cd357ebbdc9c359a53bf0 → sha256:724553f742322d67f34282be46b414572d4e0cd46ccd54d2f2a24b6a87a472b0 • ghcr.io/linuxserver/radarr latest: sha256:dfbce5095045fc1c15058318342ee590ab50379854b13464dd2ca17b10c4beb4 → sha256:df843d96b812d858b94377ffed1918424ece6735038a19e8ff93730277757b65
214 lines
4.9 KiB
Nix
214 lines
4.9 KiB
Nix
{
|
|
inputs = let
|
|
inherit (import ./inputs.nix) mkDep mkInput otherInputs;
|
|
|
|
mainInputs = {
|
|
systems = mkInput {
|
|
owner = "nix-systems";
|
|
repo = "default-linux";
|
|
};
|
|
|
|
nixpkgs = mkInput {
|
|
owner = "NixOS";
|
|
repo = "nixpkgs";
|
|
ref = "nixos-unstable";
|
|
};
|
|
|
|
home-manager = mkDep {
|
|
owner = "nix-community";
|
|
repo = "home-manager";
|
|
};
|
|
|
|
nix-on-droid = mkDep {
|
|
owner = "nix-community";
|
|
repo = "nix-on-droid";
|
|
|
|
inputs.home-manager.follows = "home-manager";
|
|
};
|
|
|
|
sops-nix = mkDep {
|
|
owner = "Mic92";
|
|
repo = "sops-nix";
|
|
};
|
|
|
|
secrets = mkDep {
|
|
type = "git";
|
|
url = "ssh://git@git.nelim.org/matt1432/nixos-secrets";
|
|
|
|
inputs.sops-nix.follows = "sops-nix";
|
|
};
|
|
|
|
jovian = mkDep {
|
|
owner = "Jovian-Experiments";
|
|
repo = "Jovian-NixOS";
|
|
};
|
|
};
|
|
in
|
|
mainInputs // otherInputs;
|
|
|
|
outputs = inputs @ {
|
|
nixpkgs,
|
|
secrets,
|
|
self,
|
|
systems,
|
|
...
|
|
}: let
|
|
inherit (import ./lib {inherit inputs;}) mkVersion mkNixOS mkNixOnDroid mkPkgs;
|
|
|
|
perSystem = attrs:
|
|
nixpkgs.lib.genAttrs (import systems) (system:
|
|
attrs (mkPkgs {inherit system nixpkgs;}));
|
|
in {
|
|
nixosModules = import ./nixosModules self;
|
|
|
|
homeManagerModules = import ./homeManagerModules self;
|
|
|
|
nixosConfigurations = {
|
|
# Desktops
|
|
wim = mkNixOS {
|
|
extraModules = [
|
|
./devices/wim
|
|
secrets.nixosModules.default
|
|
];
|
|
};
|
|
binto = mkNixOS {
|
|
# FIXME: https://github.com/NixOS/nixpkgs/issues/338315
|
|
# cudaSupport = true;
|
|
extraModules = [./devices/binto];
|
|
};
|
|
|
|
bbsteamie = mkNixOS {extraModules = [./devices/bbsteamie];};
|
|
|
|
# NAS
|
|
nos = mkNixOS {
|
|
# FIXME: https://github.com/NixOS/nixpkgs/issues/338315
|
|
# cudaSupport = true;
|
|
extraModules = [
|
|
./devices/nos
|
|
secrets.nixosModules.nos
|
|
];
|
|
};
|
|
|
|
# Build / test server
|
|
servivi = mkNixOS {
|
|
extraModules = [
|
|
./devices/servivi
|
|
secrets.nixosModules.servivi
|
|
];
|
|
};
|
|
|
|
# Home-assistant
|
|
homie = mkNixOS {
|
|
extraModules = [
|
|
./devices/homie
|
|
secrets.nixosModules.homie
|
|
];
|
|
};
|
|
|
|
# Cluster
|
|
thingone = mkNixOS {
|
|
extraModules = [
|
|
(import ./devices/cluster "thingone")
|
|
secrets.nixosModules.thingy
|
|
];
|
|
};
|
|
thingtwo = mkNixOS {
|
|
extraModules = [
|
|
(import ./devices/cluster "thingtwo")
|
|
secrets.nixosModules.thingy
|
|
];
|
|
};
|
|
|
|
live-image = mkNixOS {
|
|
extraModules = [
|
|
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix"
|
|
{
|
|
vars = {
|
|
mainUser = "nixos";
|
|
hostName = "nixos";
|
|
};
|
|
}
|
|
];
|
|
};
|
|
};
|
|
|
|
nixOnDroidConfigurations.default =
|
|
mkNixOnDroid [./devices/android];
|
|
|
|
legacyPackages =
|
|
perSystem (pkgs:
|
|
import ./legacyPackages {inherit mkVersion pkgs inputs;});
|
|
|
|
packages =
|
|
perSystem (pkgs:
|
|
import ./packages {inherit self pkgs mkVersion inputs;});
|
|
|
|
overlays = import ./overlays {};
|
|
|
|
apps =
|
|
perSystem (pkgs:
|
|
import ./apps {inherit inputs pkgs;});
|
|
|
|
devShells = perSystem (pkgs: {
|
|
default = pkgs.mkShell {
|
|
packages = [
|
|
(pkgs.writeShellScriptBin "mkIso" ''
|
|
isoConfig="nixosConfigurations.live-image.config.system.build.isoImage"
|
|
nom build $(realpath /etc/nixos)#$isoConfig
|
|
'')
|
|
];
|
|
};
|
|
|
|
node = pkgs.mkShell {
|
|
packages =
|
|
(builtins.attrValues {
|
|
inherit
|
|
(pkgs)
|
|
nodejs_latest
|
|
typescript
|
|
;
|
|
})
|
|
++ [
|
|
(pkgs.writeShellApplication {
|
|
name = "updateNpmDeps";
|
|
runtimeInputs = builtins.attrValues {
|
|
inherit
|
|
(pkgs)
|
|
prefetch-npm-deps
|
|
nodejs_latest
|
|
;
|
|
};
|
|
|
|
text = ''
|
|
npm i --package-lock-only || true # this command will fail but still updates the main lockfile
|
|
prefetch-npm-deps ./package-lock.json
|
|
'';
|
|
})
|
|
];
|
|
};
|
|
|
|
subtitles-dev = pkgs.mkShell {
|
|
packages = builtins.attrValues {
|
|
inherit
|
|
(pkgs)
|
|
nodejs_latest
|
|
ffmpeg-full
|
|
typescript
|
|
;
|
|
|
|
inherit
|
|
(pkgs.nodePackages)
|
|
ts-node
|
|
;
|
|
};
|
|
};
|
|
});
|
|
|
|
# For nix-fast-build. I use a custom output to alleviate eval time of this flake. ie. when doing nix flake show
|
|
nixFastChecks =
|
|
perSystem (pkgs:
|
|
import ./checks {inherit pkgs self;});
|
|
|
|
formatter = perSystem (pkgs: pkgs.alejandra);
|
|
};
|
|
}
|