chore: dynamic hosts, builder targets
buildbot/nix-eval Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-exodus Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-isaiah Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-linode Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-zeke Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-jeremiah Build done.
buildbot/nix-build gitea:greg/nixos#checks.aarch64-linux.nixos-nixos Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-gitlab Build done.
buildbot/nix-build Build done.
buildbot/nix-eval Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-exodus Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-isaiah Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-linode Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-zeke Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-jeremiah Build done.
buildbot/nix-build gitea:greg/nixos#checks.aarch64-linux.nixos-nixos Build done.
buildbot/nix-build gitea:greg/nixos#checks.x86_64-linux.nixos-gitlab Build done.
buildbot/nix-build Build done.
Make hosts read from directories, to limit manual changes Rename vm-gitlab -> gitlab A few reformatting and lint changes due to altered files Create builder targets for Darwin builders
This commit is contained in:
@@ -0,0 +1,205 @@
|
||||
{
|
||||
config,
|
||||
metadata,
|
||||
pkgs,
|
||||
top,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
ip = metadata.hosts.${config.networking.hostName}.ip;
|
||||
mk = file: {
|
||||
inherit file;
|
||||
owner = "buildbot";
|
||||
group = "buildbot";
|
||||
};
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
top.proxmox.nixosModules.proxmox-ve
|
||||
top.buildbot.nixosModules.buildbot-master
|
||||
top.buildbot.nixosModules.buildbot-worker
|
||||
];
|
||||
|
||||
age.secrets = {
|
||||
runner-reg.file = ../../secrets/gitlab/nixos-qemu-shell.age;
|
||||
|
||||
gitea-buildbotWorkersFile = mk ../../secrets/gitea/buildbotWorkersFile.age;
|
||||
gitea-oauthToken = mk ../../secrets/gitea/oauthToken.age;
|
||||
gitea-oauthSecret = mk ../../secrets/gitea/oauthSecret.age;
|
||||
gitea-webhookSecret = mk ../../secrets/gitea/webhookSecret.age;
|
||||
gitea-workerPassword = mk ../../secrets/gitea/workerPassword.age;
|
||||
};
|
||||
|
||||
# Bootloader.
|
||||
boot = {
|
||||
initrd.kernelModules = [
|
||||
"amdgpu"
|
||||
];
|
||||
kernelParams = [
|
||||
];
|
||||
loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
amdgpu_top
|
||||
clinfo
|
||||
curl
|
||||
gawk
|
||||
git
|
||||
mesa-demos
|
||||
unzip
|
||||
wget
|
||||
];
|
||||
|
||||
fileSystems = {
|
||||
"/nix" = {
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" ];
|
||||
device = "/dev/nvme0n1p1";
|
||||
};
|
||||
"/var" = {
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=var" ];
|
||||
device = "/dev/nvme0n1p1";
|
||||
};
|
||||
"/var/pve" = {
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=pve" ];
|
||||
device = "/dev/nvme0n1p1";
|
||||
};
|
||||
"/btrfs" = {
|
||||
fsType = "btrfs";
|
||||
device = "/dev/nvme0n1p1";
|
||||
};
|
||||
"/media/proxmox" = {
|
||||
device = "10.42.1.4:/volume1/proxmox";
|
||||
fsType = "nfs";
|
||||
options = [ "noatime" ];
|
||||
};
|
||||
};
|
||||
|
||||
greg = {
|
||||
home = true;
|
||||
kubernetes = {
|
||||
enable = true;
|
||||
vipInterface = "br0";
|
||||
vip = ip;
|
||||
priority = 254;
|
||||
};
|
||||
tailscale = {
|
||||
enable = true;
|
||||
tags = [ "home" ];
|
||||
};
|
||||
remote-builder.enable = true;
|
||||
runner = {
|
||||
enable = true;
|
||||
threads = 3;
|
||||
qemu = true;
|
||||
};
|
||||
};
|
||||
|
||||
hardware = {
|
||||
graphics = {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
};
|
||||
};
|
||||
|
||||
networking = {
|
||||
hostName = "jeremiah"; # Define your hostname.
|
||||
useDHCP = false;
|
||||
bridges.br0 = {
|
||||
interfaces = [ "enp68s0" ];
|
||||
};
|
||||
defaultGateway = {
|
||||
address = metadata.infra.gw;
|
||||
interface = "br0";
|
||||
};
|
||||
firewall.allowedTCPPorts = [
|
||||
3389
|
||||
9989 # buildbot communications port
|
||||
];
|
||||
interfaces.br0.ipv4 = {
|
||||
addresses = [
|
||||
{
|
||||
address = ip;
|
||||
prefixLength = 16;
|
||||
}
|
||||
];
|
||||
};
|
||||
nameservers = [ metadata.infra.dns ];
|
||||
};
|
||||
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
protontricks.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
buildbot-nix = {
|
||||
master = {
|
||||
enable = true;
|
||||
admins = [ "greg" ];
|
||||
authBackend = "gitea";
|
||||
# Optional to build non-default branches at a time
|
||||
branches = {
|
||||
default = {
|
||||
matchGlob = "ma*";
|
||||
registerGCRoots = false;
|
||||
updateOutputs = false;
|
||||
};
|
||||
};
|
||||
domain = "${config.networking.hostName}.shire-zebra.ts.net:8010";
|
||||
evalMaxMemorySize = 8192;
|
||||
evalWorkerCount = 8;
|
||||
gitea = {
|
||||
enable = true;
|
||||
instanceUrl = "https://src.thehellings.com";
|
||||
oauthId = "7ec9107d-379b-47c8-870f-1191956d0500";
|
||||
oauthSecretFile = config.age.secrets.gitea-oauthSecret.path;
|
||||
tokenFile = config.age.secrets.gitea-oauthToken.path;
|
||||
topic = "buildbot-nix";
|
||||
webhookSecretFile = config.age.secrets.gitea-webhookSecret.path;
|
||||
};
|
||||
showTrace = true;
|
||||
#webhookBaseUrl = "http://${config.networking.hostName}.shire-zebra.ts.net:8010";
|
||||
workersFile = config.age.secrets.gitea-buildbotWorkersFile.path;
|
||||
};
|
||||
worker = {
|
||||
enable = true;
|
||||
workerPasswordFile = config.age.secrets.gitea-workerPassword.path;
|
||||
};
|
||||
};
|
||||
displayManager = {
|
||||
defaultSession = "xfce";
|
||||
autoLogin = {
|
||||
enable = true;
|
||||
user = "greg";
|
||||
};
|
||||
};
|
||||
proxmox-ve = {
|
||||
enable = true;
|
||||
ipAddress = ip;
|
||||
};
|
||||
sunshine = {
|
||||
enable = true;
|
||||
autoStart = true;
|
||||
#capSysAdmin = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
xserver = {
|
||||
enable = true;
|
||||
desktopManager = {
|
||||
xterm.enable = true;
|
||||
xfce.enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
users.extraGroups.video.members = [ "greg" ];
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"uas"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/ffc167f5-d9e4-4b11-a5f1-f7da0550ad24";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/3047-870E";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
fileSystems."/var/lib/longhorn" = {
|
||||
device = "/dev/disk/by-uuid/1c896717-4a01-4136-825d-6c0160a78256";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp67s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp68s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlo2.useDHCP = lib.mkDefault true;
|
||||
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
Reference in New Issue
Block a user