forked from c3d2/nix-config
Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
fc6c37ab7f | |||
4e05d4a253 |
|
@ -214,7 +214,6 @@
|
||||||
|
|
||||||
pulsebert = nixosSystem' {
|
pulsebert = nixosSystem' {
|
||||||
modules = [
|
modules = [
|
||||||
"${inputs.nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
|
|
||||||
./hosts/pulsebert
|
./hosts/pulsebert
|
||||||
];
|
];
|
||||||
system = "aarch64-linux";
|
system = "aarch64-linux";
|
||||||
|
@ -222,7 +221,6 @@
|
||||||
|
|
||||||
radiobert = nixosSystem' {
|
radiobert = nixosSystem' {
|
||||||
modules = [
|
modules = [
|
||||||
"${inputs.nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
|
|
||||||
./hosts/radiobert
|
./hosts/radiobert
|
||||||
];
|
];
|
||||||
system = "aarch64-linux";
|
system = "aarch64-linux";
|
||||||
|
|
|
@ -22,6 +22,7 @@ rec {
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE9RKlt+mIew5epxHt7Gab44yFOdeD+L/EhhA6Ospzyq";
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE9RKlt+mIew5epxHt7Gab44yFOdeD+L/EhhA6Ospzyq";
|
||||||
builders = [ "ssh://client@172.22.99.110" ];
|
builders = [ "ssh://client@172.22.99.110" ];
|
||||||
wol = true;
|
wol = true;
|
||||||
|
raspberryPi = 3;
|
||||||
};
|
};
|
||||||
samba = { };
|
samba = { };
|
||||||
storage-ng.publicKey =
|
storage-ng.publicKey =
|
||||||
|
@ -119,6 +120,7 @@ rec {
|
||||||
};
|
};
|
||||||
|
|
||||||
radiobert.ip4 = "172.22.99.117";
|
radiobert.ip4 = "172.22.99.117";
|
||||||
|
radiobert.rasbperryPi = 4;
|
||||||
};
|
};
|
||||||
|
|
||||||
hqGlobal = builtins.attrNames hosts;
|
hqGlobal = builtins.attrNames hosts;
|
||||||
|
|
|
@ -31,6 +31,7 @@ in {
|
||||||
./users
|
./users
|
||||||
./stats.nix
|
./stats.nix
|
||||||
./openwebrx.nix
|
./openwebrx.nix
|
||||||
|
./raspberrypi.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
options.c3d2 = with lib;
|
options.c3d2 = with lib;
|
||||||
|
|
21
lib/raspberrypi.nix
Normal file
21
lib/raspberrypi.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{ inputs, hostRegistry, options, lib, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
enabled = hostRegistry.hosts.${config.networking.hostName} ? raspberryPi &&
|
||||||
|
hostRegistry.hosts.${config.networking.hostName}.raspberryPi != null;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = lib.optionals enabled [
|
||||||
|
"${inputs.nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
|
||||||
|
];
|
||||||
|
config = lib.mkIf enabled {
|
||||||
|
sdImage = {
|
||||||
|
compressImage = false;
|
||||||
|
imageBaseName = config.networking.hostName;
|
||||||
|
firmwareSize = 512;
|
||||||
|
};
|
||||||
|
# Don't build ZFS for aarch64 (broken?)
|
||||||
|
boot.supportedFilesystems = lib.mkForce [ "vfat" "ext4" ];
|
||||||
|
boot.zfs.enableUnstable = true;
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user