2019-08-11 19:53:02 +01:00
|
|
|
{ config, pkgs, lib, ... }:
|
2019-08-10 12:43:48 +01:00
|
|
|
|
2020-01-13 18:49:46 +00:00
|
|
|
let
|
2020-04-20 21:31:48 +02:00
|
|
|
userImports =
|
|
|
|
let
|
|
|
|
toUserPath = f: ../users/. + "/${f}";
|
|
|
|
onlyUserFiles = x:
|
|
|
|
lib.hasSuffix ".nix" x &&
|
|
|
|
x != "lib.nix"
|
|
|
|
;
|
|
|
|
userDirEntries = builtins.readDir ../users;
|
|
|
|
userFiles = builtins.filter onlyUserFiles (lib.attrNames userDirEntries);
|
|
|
|
in
|
|
|
|
builtins.map toUserPath userFiles;
|
2020-01-22 12:37:13 +01:00
|
|
|
in
|
|
|
|
{
|
2019-08-10 12:43:48 +01:00
|
|
|
imports = [
|
|
|
|
./hardware-configuration.nix
|
2019-11-01 17:15:45 +00:00
|
|
|
|
2019-08-10 12:43:48 +01:00
|
|
|
./buildkite.nix
|
2019-11-01 17:15:45 +00:00
|
|
|
./gitlab.nix
|
2020-01-12 21:15:32 +01:00
|
|
|
./hydra.nix
|
2020-04-17 23:11:02 +02:00
|
|
|
./hydra-declarative-projects.nix
|
2020-04-17 17:22:24 +01:00
|
|
|
./cache.nix
|
2020-01-15 00:15:23 -08:00
|
|
|
./nixpkgs-update.nix
|
2020-06-10 23:12:38 +02:00
|
|
|
./marvin-mk2.nix
|
2020-08-08 14:34:29 +02:00
|
|
|
./matterbridge.nix
|
2019-08-11 19:53:02 +01:00
|
|
|
|
|
|
|
../profiles/common.nix
|
|
|
|
../profiles/docker.nix
|
2020-01-13 18:49:46 +00:00
|
|
|
] ++ userImports;
|
2019-08-10 12:43:48 +01:00
|
|
|
|
|
|
|
# /boot is a mirror raid
|
|
|
|
boot.loader.grub.devices = [ "/dev/sda" "/dev/sdb" ];
|
|
|
|
boot.loader.grub.enable = true;
|
|
|
|
boot.loader.grub.version = 2;
|
|
|
|
|
|
|
|
networking.hostName = "nix-community-build01";
|
|
|
|
networking.hostId = "d2905767";
|
|
|
|
|
|
|
|
networking.usePredictableInterfaceNames = false;
|
|
|
|
networking.dhcpcd.enable = false;
|
|
|
|
systemd.network = {
|
|
|
|
enable = true;
|
|
|
|
networks."eth0".extraConfig = ''
|
|
|
|
[Match]
|
|
|
|
Name = eth0
|
|
|
|
[Network]
|
|
|
|
Address = 2a01:4f8:13b:2ceb::1/64
|
|
|
|
Gateway = fe80::1
|
|
|
|
Address = 94.130.143.84/26
|
|
|
|
Gateway = 94.130.143.65
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2019-08-12 17:24:59 +00:00
|
|
|
services.cron.enable = true;
|
|
|
|
services.cron.systemCronJobs = [
|
|
|
|
# record that this machine is alive
|
2020-02-19 16:51:19 +00:00
|
|
|
"*/5 * * * * root ${pkgs.curl}/bin/curl -X POST -sfL https://hc-ping.com/fcf6c029-5b57-44aa-b392-923f3d894dd9"
|
2019-08-12 17:24:59 +00:00
|
|
|
];
|
|
|
|
|
2019-08-10 12:43:48 +01:00
|
|
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
|
|
|
boot.supportedFilesystems = [ "zfs" ];
|
|
|
|
|
2020-04-17 22:43:39 +02:00
|
|
|
security.acme.email = "trash@nix-community.org";
|
|
|
|
security.acme.acceptTerms = true;
|
|
|
|
|
2020-04-17 22:46:20 +02:00
|
|
|
system.stateVersion = "20.03";
|
2019-08-10 12:43:48 +01:00
|
|
|
|
|
|
|
}
|