Changes:
- boot.loader: generic-extlinux-compatible (BIOS) → systemd-boot (UEFI)
- YC standard-v3 VM is UEFI by default; systemd-boot is the modern
choice for single-disk cloud VMs (no GRUB complexity)
- Comments updated: nixos-anywhere → nixos-install (in tmux), aligning
with the documented install procedure in projects/servers/muscari/SETUP.md
- .gitignore: add hosts/*/hardware-configuration.nix as defense-in-depth
(muscari uses disko and has no hw-config file; this guards future hosts
from leaking UUIDs/MACs to the public forgejo repo)
Context:
- muscari VM specs: 2 vCPU / 8 GB / 100 GB SSD (was incorrectly documented
as 4/16 in muscari/README.md; fixed there too)
- Flake builds cleanly:
nix flake show → nixosConfigurations.muscari
hostname → "muscari"
systemd-boot.enable → true
fileSystems."/" → ext4 (disko-derived)
fileSystems."/boot" → vfat (disko-derived)
Verified: nix --extra-experimental-features 'nix-command flakes' flake show
and eval .#nixosConfigurations.muscari.config.{networking.hostName,
boot.loader.systemd-boot.enable, fileSystems} all pass.
Session: verify plan
33 lines
No EOL
1.1 KiB
Nix
33 lines
No EOL
1.1 KiB
Nix
# muscari — k3s single-node cluster на YC (Debian 12 → NixOS 25.11 через nixos-install в tmux)
|
||
# https://git.iscg.dev/mikl/nix-config
|
||
|
||
{ config, pkgs, lib, ... }:
|
||
{
|
||
imports = [
|
||
./disk-config.nix
|
||
../../modules/users/mikl.nix
|
||
../../modules/services/k3s.nix
|
||
];
|
||
|
||
networking = {
|
||
hostName = "muscari";
|
||
useDHCP = true;
|
||
firewall.allowedTCPPorts = [
|
||
22 # SSH
|
||
80 # HTTP (Ingress через Traefik)
|
||
443 # HTTPS (Ingress через Traefik)
|
||
# 6443 не открываем — kubectl через SSH-туннель
|
||
];
|
||
};
|
||
|
||
# Bootloader — systemd-boot (UEFI, требуется для YC standard-v3)
|
||
boot.loader.systemd-boot.enable = true;
|
||
boot.loader.efi.canTouchEfiVariables = true;
|
||
|
||
# fileSystems — определяется через disko (см. disk-config.nix)
|
||
# Не задаём явно fileSystems."/" чтобы не конфликтовать с disko
|
||
|
||
# После nixos-install первая установка 25.11,
|
||
# потом не трогаем (NixOS convention)
|
||
system.stateVersion = "25.11";
|
||
} |