mirror of
https://github.com/srid/nixos-config.git
synced 2026-02-03 19:48:24 +08:00
Update nix-darwin for latest github-runner; refactor, following a fresh install (#51)
This commit is contained in:
parent
08f8f424c9
commit
bdba0619ac
12 changed files with 167 additions and 61 deletions
|
|
@ -4,7 +4,7 @@
|
|||
{
|
||||
imports = [
|
||||
flake.inputs.self.darwinModules.default
|
||||
# ../nix-darwin/ci.nix
|
||||
../nix-darwin/ci/github-runner.nix
|
||||
../nix-darwin/zsh-completion-fix.nix
|
||||
];
|
||||
|
||||
|
|
|
|||
|
|
@ -10,13 +10,13 @@
|
|||
{ flake, modulesPath, ... }: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
flake.inputs.disko.nixosModules.disko
|
||||
../../nixos/self/primary-as-admin.nix
|
||||
../../nixos/server/harden/basics.nix
|
||||
../../nixos/current-location.nix
|
||||
./hardware-configuration.nix
|
||||
../../../nixos/self/primary-as-admin.nix
|
||||
../../../nixos/server/harden/basics.nix
|
||||
../../../nixos/current-location.nix
|
||||
./parallels-vm.nix
|
||||
# Dev
|
||||
./dev.nix
|
||||
# ./dev.nix
|
||||
];
|
||||
|
||||
# Basics
|
||||
|
|
@ -30,10 +30,8 @@
|
|||
MAILADDR srid@srid.ca
|
||||
'';
|
||||
};
|
||||
disko.devices = import ../../nixos/disko/trivial.nix { device = "/dev/sda"; };
|
||||
networking = {
|
||||
hostName = "linux-builder";
|
||||
networkmanager.enable = true;
|
||||
hostName = "parallels-linux-builder";
|
||||
};
|
||||
|
||||
# Distributed Builder
|
||||
|
|
@ -42,6 +40,6 @@
|
|||
services.openssh.enable = true;
|
||||
users.users.${flake.config.people.myself}.openssh.authorizedKeys.keys = [
|
||||
# macos /etc/ssh/ssh_host_ed25519_key.pub
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOPGfskkyhM0wefy0Sex2t5GENEHTIZAWrb9LzRN0R9x"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICra+ZidiwrHGjcGnyqPvHcZDvnGivbLMayDyecPYDh0"
|
||||
];
|
||||
}
|
||||
|
|
@ -3,8 +3,8 @@
|
|||
imports = [
|
||||
flake.inputs.self.nixosModules.home-manager
|
||||
flake.inputs.self.nixosModules.my-home
|
||||
../../nixos/nix.nix
|
||||
../../nixos/docker.nix
|
||||
../../../nixos/nix.nix
|
||||
../../../nixos/docker.nix
|
||||
];
|
||||
|
||||
programs.nix-ld.enable = true; # For vscode-server
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
# 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, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "usbhid" "sr_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{
|
||||
device = "/dev/disk/by-uuid/eb7e394a-1c20-4996-a392-efa3b69665ed";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{
|
||||
device = "/dev/disk/by-uuid/423B-8BF8";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
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.enp0s5.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
|
||||
hardware.parallels.enable = true;
|
||||
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "prl-tools" ];
|
||||
}
|
||||
15
systems/parallels-vm/nix-darwin/use.nix
Normal file
15
systems/parallels-vm/nix-darwin/use.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{ flake, ... }:
|
||||
|
||||
{
|
||||
# If not using linux-builder, use a VM
|
||||
nix.distributedBuilds = true;
|
||||
nix.buildMachines = [{
|
||||
hostName = "parallels-linux-builder";
|
||||
systems = [ "aarch64-linux" "x86_64-linux" ];
|
||||
supportedFeatures = [ "kvm" "benchmark" "big-parallel" ];
|
||||
maxJobs = 6; # 6 cores
|
||||
protocol = "ssh-ng";
|
||||
sshUser = flake.config.people.myself;
|
||||
sshKey = "/etc/ssh/ssh_host_ed25519_key";
|
||||
}];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue