Skip to content

Instantly share code, notes, and snippets.

@grahamc
Created April 20, 2020 21:44
Show Gist options
  • Save grahamc/95a6225ee6830c9d834f1d1a23779541 to your computer and use it in GitHub Desktop.
Save grahamc/95a6225ee6830c9d834f1d1a23779541 to your computer and use it in GitHub Desktop.
let
locations = {
berkshires = {
latitude = 42.5;
longitude = -73.2;
timezone = "America/New_York";
remote_timezones = [ "Europe/Paris" ];
};
texas = {
latitude = 32.7766652;
longitude = -96.796989;
timezone = "America/Chicago";
remote_timezones = [ "America/New_York" "Europe/Paris" ];
};
bay-area = {
latitude = 37.36;
longitude = -122.03;
timezone = "America/Los_Angeles";
remote_timezones = [ "America/New_York" "Europe/Paris" ];
};
london = {
latitude = 51.50722;
longitude = 0.1275;
timezone = "Europe/London";
remote_timezones = [ "America/New_York" ];
};
dublin = {
latitude = 53.350140;
longitude = -6.266155;
timezone = "Europe/Dublin";
remote_timezones = [ "America/New_York" ];
};
brno = {
latitude = 49.195061;
longitude = 16.606836;
timezone = "Europe/Prague";
remote_timezones = [ "America/New_York" ];
};
paris = {
latitude = 48.859489;
longitude = 2.320582;
timezone = "Europe/Paris";
remote_timezones = [ "America/New_York" ];
};
};
in
rec {
location = locations.berkshires;
inherit (location) latitude longitude timezone;
hashedPassword = "$6$$/.q/.";
buildMachines = [
{
hostName = "rpi1-0";
maxJobs = 1;
sshUser = "root";
sshKey = "/rpool/persist/private/root/rpi";
system = "armv6l-linux";
supportedFeatures = [ "big-parallel" ];
}
{
hostName = "rpi1-1";
maxJobs = 1;
sshUser = "root";
sshKey = "/rpool/persist/private/root/rpi";
system = "armv6l-linux";
supportedFeatures = [ "big-parallel" ];
}
{
hostName = "ndndx";
maxJobs = 4;
#sshKey = "/root/.ssh/id_rsa";
system = "x86_64-darwin";
supportedFeatures = [ "big-parallel" ];
}
];
helvetica_location = ./helvetica.ttc;
secure-boot = {
key = "/rpool/persist/private/secure-boot/db.key";
certificate = "/rpool/persist/private/secure-boot/db.crt";
};
wireguard = {
ips = [ "10.10.2.10/24" ];
privateKeyFile = "/rpool/persist/private/wireguard/private";
peers = [
{
publicKey = "IMj8M5CqQzpKPKlqdjwn3ui0r79tb4YSM/+KYSpRRgw=";
allowedIPs = [ "10.10.2.16/32" ];
persistentKeepalive = 25;
endpoint = "10.5.3.16:41741";
}
{
publicKey = "kG7wx7RSayTq7xEhsuCGCSn4pVXTu53Y5Ifb9F74fDs=";
allowedIPs = [ "10.10.2.20/32" ];
}
];
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment