hosts/europa: init

This commit is contained in:
Oystein Kristoffer Tveit 2024-07-18 15:10:36 +02:00
parent 881aaedd4a
commit 221e425235
Signed by: oysteikt
GPG Key ID: 9F2F7D8250F35146
9 changed files with 211 additions and 35 deletions

View File

@ -3,6 +3,7 @@ keys:
- &host_tsuki age1c92j4w0gqh32hwssl5m2mfrggssxax9pge8qxwytv9lmrnfttcvqdrgsst
- &host_kasei age1eu2a6m3adakfzelfa9pqpl74a5dz0wkyr0v7gegm5ajnx7aqmqcqsp2ftc
- &host_dosei age179y7apa80p9unvyjtsphpzyhve90ex986vlxkx43xt9n6m7en3csqnug7c
- &host_europa age14mer45e52r2q4uz8n3fmv69tvk8gvwany4m4ndudud8ajv3jm4nqdj9m6a
- &home age10f4a5acpar8vwz3v298r3nv7gggfpmyh4wxpkc2hwq9paq0scf8qee8lau
creation_rules:
@ -14,6 +15,7 @@ creation_rules:
- *host_tsuki
- *host_kasei
- *host_dosei
- *host_europa
- *home
- path_regex: secrets/home.yaml
@ -43,3 +45,10 @@ creation_rules:
- *gpg_h7x4
age:
- *host_dosei
- path_regex: secrets/europa.yaml
key_groups:
- pgp:
- *gpg_h7x4
age:
- *host_europa

View File

@ -23,6 +23,7 @@ Here are some of the interesting files and dirs:
| `Tsuki` | Dell Poweredge r710 server | Data storage / Build server / Selfhosted services. This server hosts a wide variety of services, including websites, matrix server, git repos, CI/CD and more. **This is probably the most interesting machine to pick config from** |
| `Kasei` | AMD Zen 2 CPU / Nvidia GPU - desktop computer | Semi-daily driver. This is my main computer at home. |
| `Dosei` | Dell Optiplex | Work computer, mostly used for development and testing. |
| `Europa` | Dell Optiplex | Other work computer, used as nix builder for `Dosei`. |
## home-manager configuration

View File

@ -213,6 +213,7 @@
in {
dosei = nixSys "dosei" { };
kasei = nixSys "kasei" { };
europa = nixSys "europa" { };
tsuki = nixSys "tsuki" {
modules = [
matrix-synapse-next.nixosModules.default

View File

@ -0,0 +1,95 @@
{ config, pkgs, lib, ... }:
{
imports = [
./hardware-configuration.nix
./services/avahi.nix
./services/docker.nix
];
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
boot.binfmt.emulatedSystems = [
"aarch64-linux"
"armv7l-linux"
];
i18n.defaultLocale = "en_US.UTF-8";
services.udev.packages = with pkgs; [
segger-jlink
];
system.stateVersion = "24.05";
machineVars = {
headless = true;
gaming = false;
development = true;
creative = false;
dataDrives = let
main = "/data";
in {
drives = { inherit main; };
default = main;
};
};
systemd.targets = {
sleep.enable = false;
suspend.enable = false;
hibernate.enable = false;
hybrid-sleep.enable = false;
};
# security.pam.services.login.unixAuth = true;
# systemd.network = {
# enable = true;
# # broken
# wait-online.enable = true;
# };
networking = {
hostName = "europa";
networkmanager.enable = true;
# TODO: reenable
firewall.enable = false;
# hostId = "007f0201";
};
services = {
openssh = {
enable = true;
settings.X11Forwarding = true;
settings.PasswordAuthentication = lib.mkForce true;
};
# xserver = {
# # displayManager.gdm.enable = true;
# # desktopManager.gnome.enable = true;
# # videoDrivers = [ "nvidia" ];
# };
# tailscale.enable = true;
};
hardware = {
bluetooth.enable = true;
# cpu.amd.updateMicrocode = true;
enableRedistributableFirmware = true;
keyboard.zsa.enable = true;
opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
};
# nvidia = {
# modesetting.enable = true;
# nvidiaSettings = true;
# };
};
programs.usbtop.enable = true;
}

View File

@ -0,0 +1,40 @@
# 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 =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/2de4150d-e418-4f22-a516-3f35352eb66a";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/12CE-A600";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
swapDevices =
[ { device = "/dev/disk/by-uuid/8c8bc640-83f4-4eee-909b-457989cebfe4"; }
];
# 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.eno1.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@ -0,0 +1,4 @@
{ ... }:
{
home.stateVersion = "24.05";
}

View File

@ -0,0 +1,13 @@
{ config, pkgs, lib, ... }:
{
services.avahi = {
enable = true;
publish.enable = true;
publish.addresses = true;
publish.domain = true;
publish.hinfo = true;
publish.userServices = true;
publish.workstation = true;
extraServiceFiles.ssh = "${pkgs.avahi}/etc/avahi/services/ssh.service";
};
}

View File

@ -0,0 +1,4 @@
{ config, pkgs, lib, ... }:
{
virtualisation.docker.enable = true;
}

View File

@ -23,60 +23,69 @@ sops:
- recipient: age1c92j4w0gqh32hwssl5m2mfrggssxax9pge8qxwytv9lmrnfttcvqdrgsst
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSAweE1kMlFnZVZxZ0dhblVn
SjBrU3lUSlFtL2lCWm1VRUtocTdCWVg2aUJFCmc5dEJNdlpGSnFJSjhCNEZmQVc2
VVplaldBUlV6TSt1V0lJdTNGWEJpL0kKLS0tIGVhVng4c28wVTdpVXdrdll6N3dj
S0N3UldMUWl3VTBBajZkbTFQSzJVNzQKkjgkwjVL3tTJGL4raaRRAflyen6lrCjf
qIDU6yVaRPoeg4PMQyjT8B7Lvw/MAAir+v4dO+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Ri00OuvChEg+oJJ+U0gfwcWJKBkUKuT2Qw==
-----END AGE ENCRYPTED FILE-----
- recipient: age179y7apa80p9unvyjtsphpzyhve90ex986vlxkx43xt9n6m7en3csqnug7c
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSB3RVIzVFlVVDdqU2tFZ3lD
T2NtdjBabmU1cVc3QlRkWnU5ZldodmlHZkJRCjZIcFllSGVoSEVtUkFFVXI1eXd6
cjhRbVhLM25HQjlobnNOK0ZiNGE3R1EKLS0tIGdES2I4Y3ZCWWtOVkNyZDZ3V0d3
V3NFU3ZuUjFxeHNyUGZXdW9aUElKM1UKutap6vQBYUAuDrnFKBa1J6PcjeTV03a1
G6+jlJsBhMlUkiavWiqZ4JuGtSF3tCPZwf+NzuOZfGfjD3YOVHqY/w==
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBERjM5bEpySWMzUFdidkk4
cDJUVGUralN4RjZoN0E1QTh2eGVHazZiQmxjClB1QnB2ZmVvbVo3SnZLNnlPejV1
eGZjUDhDVVRNUVlXdVJDWSsxQlR4S00KLS0tIGtDU1R4UnRwcEJJcmtYei9nWHFH
M0VPbTdsTU4xRll1ZG1LcndTZmx3NHcKwA6fUauOTUHadUaion9dfjQPvUxwUIdt
ZaHSpuj8usrKd901BvDRxVGv23FAxBb9Ylr2Az+MhHYaVGU/kbQ9mA==
-----END AGE ENCRYPTED FILE-----
- recipient: age14mer45e52r2q4uz8n3fmv69tvk8gvwany4m4ndudud8ajv3jm4nqdj9m6a
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBmZGk1TVVFZ3NxV0NqUEtD
bUNaWFpic0JBQTY3YXRRNmM2SmVzRVdlS1YwCmx1R2tCSndFU2VnU2VFNC9TNEVt
R3diVE5LK2Q0Y2FrZUpUUDQyQldNYUkKLS0tIEE2SWU1NmlkcE8xMHJhaHNhRHhT
enl1ZlNhNjZIU2o5ejh6TjJUWVJQLzAKhhm88Am5Dfng4SRmEGEbsYne/9SrtNxW
5ntmc8AEMN3v1g8hEIOvllms5gqiZP1LUrTAvYddI0+ykwPuTY06Jw==
-----END AGE ENCRYPTED FILE-----
- recipient: age10f4a5acpar8vwz3v298r3nv7gggfpmyh4wxpkc2hwq9paq0scf8qee8lau
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBJelFCVGo4L0QrUnNqdWRm
cTR4TnJNdGx5SE82cEYzMk9ybmVzeUQ1MHlJCmFEbXZCVFBQUmVFMXFlVnQ1OFdI
R0RDNU5XYVNUbmRZSUJUU1VQQk1SdlEKLS0tIG02Q0dIdlJiRWt2cFJTN1VSbTVW
MGo3NEZyVlVWUDlVdGZyT2dVV3lxeUEKZGLbJ/PAmHdzfUfDvAQD/Nq179ooElth
mfF8FLeFoydSYAxXCDAw/JgjUPXckyjPXEjo3dnSBVec1Q6qHhPBpQ==
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBka0tVODhFWHo4Q3RSZG5h
K0dwMEg1SVVtTUljamxCNEMxdGg5a1IvRVhnCmpnNEdEc3BPcVRVS1VzOUFNZFBU
bEtqNlgzWGM0Um5RMHNKUWdRZS95TFkKLS0tIFNKZ2dDS1Nnb2JKeW92djhUOWRG
cm15UjQ4S0xoclpLV0pYcmJzM1g2eDAKAjJUhGgicEG3dj8BdMjPvr9MC/c+oIGx
kPxtKQ5REb5UolEuBBsWapKhKeXLFtTsV/qGOokO34HT1PqZI37Ikw==
-----END AGE ENCRYPTED FILE-----
lastmodified: "2024-07-08T12:29:09Z"
mac: ENC[AES256_GCM,data:z7J2kMlnqp6RJJj//O8j8W6O7HJkTGAbW0LW4Z6F4m0Fj18bylMQJ7kbNmf7mK5PHnItdHFnWJ/kY1vaXN7gD1SJccZ+jJcWI+nR3i5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