| 31 Dec 2023 |
hexa | npkgs is probably the node nixpkgs? | 01:37:20 |
hexa | let
sources = import ./nix/sources.nix;
defaultSystem = "x86_64-linux";
defaultPkgs = sources."nixos-23.11";
lib = import (defaultPkgs + "/lib");
machines = {
"archive.darmstadt.ccc.de" = {};
"bitwarden.darmstadt.ccc.de" = {};
"md.darmstadt.ccc.de" = {};
"monitoring.darmstadt.ccc.de" = {};
"mx1.darmstadt.ccc.de" = {
system = "aarch64-linux";
};
"proxmox.darmstadt.ccc.de" = {};
"sso1.darmstadt.ccc.de" = {};
"sso2.darmstadt.ccc.de" = {};
"todo.darmstadt.ccc.de" = {};
"wiki.darmstadt.ccc.de" = {};
};
# per machine entrypoint
mkMachine = hostName: {
system ? defaultSystem,
packages ? defaultPkgs,
...
}: {
imports = [
./common.nix
./machines/${hostName}
];
nixpkgs = {
inherit system;
};
};
in
{
meta = {
# https://colmena.cli.rs/unstable/tutorial/index.html#basic-configuration
nixpkgs = import defaultPkgs {};
# Allow overriding package set and system architecture per machine
nodeNixpkgs = lib.mapAttrs (hostName: {
packages ? defaultPkgs,
system ? defaultSystem,
...
}: (import packages { inherit system; }))
machines;
};
}
// lib.mapAttrs mkMachine machines
| 01:37:47 |
hexa | * let
sources = import ./nix/sources.nix;
defaultSystem = "x86_64-linux";
defaultPkgs = sources."nixos-23.11";
lib = import (defaultPkgs + "/lib");
machines = {
"archive.darmstadt.ccc.de" = {};
"bitwarden.darmstadt.ccc.de" = {};
"md.darmstadt.ccc.de" = {};
"monitoring.darmstadt.ccc.de" = {};
"mx1.darmstadt.ccc.de" = {
system = "aarch64-linux";
};
"proxmox.darmstadt.ccc.de" = {};
"sso1.darmstadt.ccc.de" = {};
"sso2.darmstadt.ccc.de" = {};
"todo.darmstadt.ccc.de" = {};
"wiki.darmstadt.ccc.de" = {};
};
# per machine entrypoint
mkMachine = hostName: {
system ? defaultSystem,
packages ? defaultPkgs,
...
}: {
imports = [
./common.nix
./machines/${hostName}
];
nixpkgs = {
inherit system;
};
};
in
{
meta = {
# https://colmena.cli.rs/unstable/tutorial/index.html#basic-configuration
nixpkgs = import defaultPkgs {};
# Allow overriding package set and system architecture per machine
nodeNixpkgs = lib.mapAttrs (hostName: {
packages ? defaultPkgs,
system ? defaultSystem,
...
}: (import packages { inherit system; }))
machines;
};
}
// lib.mapAttrs mkMachine machines
| 01:37:49 |
hexa | this is the hive.nix | 01:37:55 |
raitobezarius | shoudln't this be localSystem ? | 01:46:39 |
raitobezarius | or crossSystem ? | 01:46:42 |
hexa | in L52? | 01:47:03 |
raitobezarius | L36 | 01:47:10 |
raitobezarius | and L52 too | 01:47:14 |
raitobezarius | but I think it works | 01:47:17 |
raitobezarius | localSystem works too for me | 01:47:26 |
raitobezarius | I wonder if it could have an effect to use the system rather than localSystem | 01:47:39 |
raitobezarius | in the rest of the machinery | 01:47:43 |