Merge pull request #443 from genebean/k8s-and-cosmic

k8s and cosmic
This commit is contained in:
Gene Liverman 2024-08-12 15:58:19 -04:00 committed by GitHub
commit 0cccdf2c03
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 178 additions and 47 deletions

170
flake.lock generated
View file

@ -41,11 +41,11 @@
"onchg": "onchg" "onchg": "onchg"
}, },
"locked": { "locked": {
"lastModified": 1720429515, "lastModified": 1723077491,
"narHash": "sha256-r73eyaZzaNgysusdaFmanOHcYMVnRxdAYzD4BvkBjmU=", "narHash": "sha256-Zdv5L9Uhh84HTppHszAFvTAUzZfvHY+MTEcQwHc6dIk=",
"owner": "aksiksi", "owner": "aksiksi",
"repo": "compose2nix", "repo": "compose2nix",
"rev": "a55aea08f1eb34cc1681c9ea2d7b42b58730df5d", "rev": "e5f35685dd09435f648ec827335ab307b7c4574d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -57,11 +57,11 @@
"config": { "config": {
"locked": { "locked": {
"dir": "templates/config", "dir": "templates/config",
"lastModified": 1715288913, "lastModified": 1719931926,
"narHash": "sha256-NQhxnFCAUj4x5t878Gpzb6xlRpr1V7bm5AEoqCVaJbk=", "narHash": "sha256-B8j9lHX0LqWlZkm8JxZRN6919RQjJEu/1J1SR8pU/ww=",
"owner": "stackbuilders", "owner": "stackbuilders",
"repo": "nixpkgs-terraform", "repo": "nixpkgs-terraform",
"rev": "4f09d5af5c1782414ff27caab6f3abd84e516ded", "rev": "034287ee462c87dadc14a94d4b53a48ed66c7b3d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -78,11 +78,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1721735625, "lastModified": 1723426710,
"narHash": "sha256-4T0FK0b3Q7Dd7oj79M7GhA9+YqKxxGT0iN+h8yqdP7s=", "narHash": "sha256-yrS9al6l3fYfFfvovnyBWnyELDQOdfKyai4K/jKgoBw=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "4698b1ef375e9c904037e0b2049aa73d39ac1b2d", "rev": "0d510fe40b56ed74907a021d7e1ffd0042592914",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -92,6 +92,22 @@
} }
}, },
"flake-compat": { "flake-compat": {
"flake": false,
"locked": {
"lastModified": 1717312683,
"narHash": "sha256-FrlieJH50AuvagamEvWMIE6D2OAnERuDboFDYAED/dE=",
"owner": "nix-community",
"repo": "flake-compat",
"rev": "38fd3954cf65ce6faf3d0d45cd26059e059f07ea",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "flake-compat",
"type": "github"
}
},
"flake-compat_2": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1696426674, "lastModified": 1696426674,
@ -112,11 +128,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1706830856, "lastModified": 1722555600,
"narHash": "sha256-a0NYyp+h9hlb7ddVz4LUn1vT/PLwqfrWYcHMvFB1xYg=", "narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "b253292d9c0a5ead9bc98c4e9a26c6312e27d69f", "rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -202,11 +218,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1721719500, "lastModified": 1722924007,
"narHash": "sha256-nnkqjv4Y37Hydjh6HE9wW4kSkV5Q7q4iIXlL5lwUFOw=", "narHash": "sha256-+CQDamNwqO33REJLft8c26NbUi2Td083hq6SvAm2xkU=",
"owner": "lnl7", "owner": "lnl7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "884f3fe6d9bf056ba0017c132c39c1f0d07d4fec", "rev": "91010a5613ffd7ee23ee9263213157a1c422b705",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -292,13 +308,36 @@
"type": "github" "type": "github"
} }
}, },
"nixos-cosmic": {
"inputs": {
"flake-compat": "flake-compat",
"nixpkgs": [
"nixpkgs"
],
"nixpkgs-stable": "nixpkgs-stable",
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1723340593,
"narHash": "sha256-SYrNboypGpiFlE6g3UWdfqJeMihR0dBJPAwTwO6T64A=",
"owner": "lilyinstarlight",
"repo": "nixos-cosmic",
"rev": "94a1e5a4888ab0cb5ad0fe602d03d867a320348b",
"type": "github"
},
"original": {
"owner": "lilyinstarlight",
"repo": "nixos-cosmic",
"type": "github"
}
},
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1721754224, "lastModified": 1723310128,
"narHash": "sha256-JEVfxzZRo+/zdWKBjHpAUG905SDZL9fmoLJxf9b5CGU=", "narHash": "sha256-IiH8jG6PpR4h9TxSGMYh+2/gQiJW9MwehFvheSb5rPc=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "405b654893aba16c8014de6a17e84439d3fb8e46", "rev": "c54cf53e022b0b3c1d3b8207aa0f9b194c24f0cf",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -321,6 +360,22 @@
"type": "indirect" "type": "indirect"
} }
}, },
"nixpkgs-1_0": {
"locked": {
"lastModified": 1699291058,
"narHash": "sha256-5ggduoaAMPHUy4riL+OrlAZE14Kh7JWX4oLEs22ZqfU=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "41de143fda10e33be0f47eab2bfe08a50f234267",
"type": "github"
},
"original": {
"owner": "nixos",
"repo": "nixpkgs",
"rev": "41de143fda10e33be0f47eab2bfe08a50f234267",
"type": "github"
}
},
"nixpkgs-24_05": { "nixpkgs-24_05": {
"locked": { "locked": {
"lastModified": 1717144377, "lastModified": 1717144377,
@ -338,23 +393,33 @@
}, },
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"dir": "lib", "lastModified": 1722555339,
"lastModified": 1706550542, "narHash": "sha256-uFf2QeW7eAHlYXuDktm9c25OxOyCoUOQmh5SZ9amE5Q=",
"narHash": "sha256-UcsnCG6wx++23yeER4Hg18CXWbgNpqNXcHIo5/1Y+hc=", "type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1722987190,
"narHash": "sha256-68hmex5efCiM2aZlAAEcQgmFI4ZwWt8a80vOeB/5w3A=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "97b17f32362e475016f942bbdfda4a4a72a8a652", "rev": "21cc704b5e918c5fbf4f9fff22b4ac2681706d90",
"type": "github" "type": "github"
}, },
"original": { "original": {
"dir": "lib",
"owner": "NixOS", "owner": "NixOS",
"ref": "nixos-unstable", "ref": "nixos-24.05",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
} }
}, },
"nixpkgs-stable": { "nixpkgs-stable_2": {
"locked": { "locked": {
"lastModified": 1721524707, "lastModified": 1721524707,
"narHash": "sha256-5NctRsoE54N86nWd0psae70YSLfrOek3Kv1e8KoXe/0=", "narHash": "sha256-5NctRsoE54N86nWd0psae70YSLfrOek3Kv1e8KoXe/0=",
@ -374,20 +439,21 @@
"inputs": { "inputs": {
"config": "config", "config": "config",
"flake-parts": "flake-parts", "flake-parts": "flake-parts",
"nixpkgs": [ "nixpkgs-1_0": "nixpkgs-1_0",
"nixpkgs-1_6": [
"nixpkgs" "nixpkgs"
], ],
"nixpkgs-unstable": [ "nixpkgs-1_9": [
"nixpkgs-unstable" "nixpkgs-unstable"
], ],
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1719931926, "lastModified": 1723144319,
"narHash": "sha256-B8j9lHX0LqWlZkm8JxZRN6919RQjJEu/1J1SR8pU/ww=", "narHash": "sha256-yvGkbgDRhm+BVO2ivARcHjzNw/FiYQNL5QbbTCahr0E=",
"owner": "stackbuilders", "owner": "stackbuilders",
"repo": "nixpkgs-terraform", "repo": "nixpkgs-terraform",
"rev": "034287ee462c87dadc14a94d4b53a48ed66c7b3d", "rev": "6b5daf242e5dea86e9ae9c04971f08bedaaac440",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -398,11 +464,11 @@
}, },
"nixpkgs-unstable": { "nixpkgs-unstable": {
"locked": { "locked": {
"lastModified": 1721622093, "lastModified": 1723221148,
"narHash": "sha256-iQ+quy3A1EKeFyLyAtjhgSvZHH7r+xybXZkxMhasN4I=", "narHash": "sha256-7pjpeQlZUNQ4eeVntytU3jkw9dFK3k1Htgk2iuXjaD8=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "453402b94f39f968a7c27df28e060f69e4a50c3b", "rev": "154bcb95ad51bc257c2ce4043a725de6ca700ef6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -430,11 +496,11 @@
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1721548954, "lastModified": 1723282977,
"narHash": "sha256-7cCC8+Tdq1+3OPyc3+gVo9dzUNkNIQfwSDJ2HSi2u3o=", "narHash": "sha256-oTK91aOlA/4IsjNAZGMEBz7Sq1zBS0Ltu4/nIQdYDOg=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "63d37ccd2d178d54e7fb691d7ec76000740ea24a", "rev": "a781ff33ae258bbcfd4ed6e673860c3e923bf2cc",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -490,6 +556,7 @@
"nix-darwin": "nix-darwin", "nix-darwin": "nix-darwin",
"nix-flatpak": "nix-flatpak", "nix-flatpak": "nix-flatpak",
"nix-homebrew": "nix-homebrew", "nix-homebrew": "nix-homebrew",
"nixos-cosmic": "nixos-cosmic",
"nixos-hardware": "nixos-hardware", "nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_3", "nixpkgs": "nixpkgs_3",
"nixpkgs-terraform": "nixpkgs-terraform", "nixpkgs-terraform": "nixpkgs-terraform",
@ -498,10 +565,31 @@
"sops-nix": "sops-nix" "sops-nix": "sops-nix"
} }
}, },
"rust-overlay": {
"inputs": {
"nixpkgs": [
"nixos-cosmic",
"nixpkgs"
]
},
"locked": {
"lastModified": 1723256423,
"narHash": "sha256-9iDTrfVM+mbcad31a47oqW8t8tfSA4C/si6F8F2DO/w=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "615cfd85b4d9c51811a8d875374268fab5bd4089",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"simple-nixos-mailserver": { "simple-nixos-mailserver": {
"inputs": { "inputs": {
"blobs": "blobs", "blobs": "blobs",
"flake-compat": "flake-compat", "flake-compat": "flake-compat_2",
"nixpkgs": "nixpkgs_4", "nixpkgs": "nixpkgs_4",
"nixpkgs-24_05": "nixpkgs-24_05", "nixpkgs-24_05": "nixpkgs-24_05",
"utils": "utils" "utils": "utils"
@ -526,14 +614,14 @@
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
], ],
"nixpkgs-stable": "nixpkgs-stable" "nixpkgs-stable": "nixpkgs-stable_2"
}, },
"locked": { "locked": {
"lastModified": 1721688883, "lastModified": 1723454404,
"narHash": "sha256-9jsjsRKtJRqNSTXKj9zuDFRf2PGix30nMx9VKyPgD2U=", "narHash": "sha256-Zhcf1TMDYb0BxDHKhEKCKFb1qi2vwlX0BgJPwk9Gd3E=",
"owner": "mic92", "owner": "mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "aff2f88277dabe695de4773682842c34a0b7fd54", "rev": "ab2d1ffeb5b85da2f6537beb2fe05da54276c261",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -41,12 +41,17 @@
# Manage Homebrew itself # Manage Homebrew itself
nix-homebrew.url = "github:zhaofengli-wip/nix-homebrew"; nix-homebrew.url = "github:zhaofengli-wip/nix-homebrew";
nixos-cosmic = {
url = "github:lilyinstarlight/nixos-cosmic";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-hardware.url = "github:NixOS/nixos-hardware/master"; nixos-hardware.url = "github:NixOS/nixos-hardware/master";
nixpkgs-terraform = { nixpkgs-terraform = {
url = "github:stackbuilders/nixpkgs-terraform"; url = "github:stackbuilders/nixpkgs-terraform";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs-1_6.follows = "nixpkgs";
inputs.nixpkgs-unstable.follows = "nixpkgs-unstable"; inputs.nixpkgs-1_9.follows = "nixpkgs-unstable";
}; };
simple-nixos-mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-24.05"; simple-nixos-mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-24.05";
@ -60,8 +65,9 @@
}; # end inputs }; # end inputs
outputs = inputs@{ outputs = inputs@{
self, nixpkgs, nixpkgs-unstable, compose2nix, disko, genebean-omp-themes, self, nixpkgs, nixpkgs-unstable, compose2nix, disko, genebean-omp-themes,
home-manager, nix-darwin, nix-flatpak, nix-homebrew, nixos-hardware, nixpkgs-terraform, home-manager, nix-darwin, nix-flatpak, nix-homebrew, nixos-cosmic,
simple-nixos-mailserver, sops-nix, ... }: let nixos-hardware, nixpkgs-terraform, simple-nixos-mailserver, sops-nix, ...
}: let
# creates a macOS system config # creates a macOS system config
darwinHostConfig = { system, hostname, username, additionalModules, additionalSpecialArgs }: nix-darwin.lib.darwinSystem { darwinHostConfig = { system, hostname, username, additionalModules, additionalSpecialArgs }: nix-darwin.lib.darwinSystem {
@ -217,6 +223,7 @@
hostname = "rainbow-planet"; hostname = "rainbow-planet";
username = "gene"; username = "gene";
additionalModules = [ additionalModules = [
nixos-cosmic.nixosModules.default
nixos-hardware.nixosModules.dell-xps-13-9360 nixos-hardware.nixosModules.dell-xps-13-9360
]; ];
additionalSpecialArgs = {}; additionalSpecialArgs = {};

View file

@ -20,6 +20,9 @@
# host specific apps # host specific apps
boinc boinc
brightnessctl brightnessctl
butane
cilium-cli
displaylink
gnome.gnome-tweaks gnome.gnome-tweaks
gnome.nautilus gnome.nautilus
gnomeExtensions.dash-to-panel gnomeExtensions.dash-to-panel
@ -27,7 +30,12 @@
gnomeExtensions.pop-shell gnomeExtensions.pop-shell
gnomeExtensions.tailscale-qs gnomeExtensions.tailscale-qs
go go
hubble
hugo hugo
kubectl
kubectx
kubernetes-helm
kubeseal
networkmanager-openvpn networkmanager-openvpn
nodejs nodejs
pavucontrol pavucontrol
@ -36,8 +44,11 @@
pop-gtk-theme pop-gtk-theme
pop-icon-theme pop-icon-theme
pop-launcher pop-launcher
#quickemu
rclone rclone
rclone-browser rclone-browser
step-cli
virt-manager
whalebird whalebird
wmctrl wmctrl
@ -55,6 +66,7 @@
networking = { networking = {
networkmanager.enable = true; networkmanager.enable = true;
useNetworkd = true;
}; };
programs = { programs = {
@ -76,6 +88,7 @@
services = { services = {
boinc.enable = true; boinc.enable = true;
desktopManager.cosmic.enable = true;
desktopManager.plasma6.enable = true; desktopManager.plasma6.enable = true;
displayManager.sddm = { displayManager.sddm = {
enable = true; enable = true;
@ -145,6 +158,8 @@
}; };
}; };
users.extraGroups.vboxusers.members = [ "${username}" ];
# Define a user account. Don't forget to set a password with passwd. # Define a user account. Don't forget to set a password with passwd.
users.users.${username} = { users.users.${username} = {
isNormalUser = true; isNormalUser = true;
@ -154,4 +169,17 @@
tailscale-systray tailscale-systray
]; ];
}; };
virtualisation = {
containers.enable = true;
libvirtd = {
enable = true;
qemu.package = pkgs.qemu_kvm;
};
podman = {
enable = true;
defaultNetwork.settings.dns_enabled = true;
};
virtualbox.host.enable = true;
};
} }

View file

@ -43,10 +43,18 @@
"flakes" "flakes"
"nix-command" "nix-command"
]; ];
extra-substituters = [ # extra-substituters = [
# ];
# extra-trusted-public-keys = [
# ];
substituters = [
"https://cache.nixos.org" # default one
"https://cosmic.cachix.org/"
"https://nixpkgs-terraform.cachix.org" "https://nixpkgs-terraform.cachix.org"
]; ];
extra-trusted-public-keys = [ trusted-public-keys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" # default one
"cosmic.cachix.org-1:Dya9IyXD4xdBehWjrkPv6rtxpmMdRel02smYzA85dPE="
"nixpkgs-terraform.cachix.org-1:8Sit092rIdAVENA3ZVeH9hzSiqI/jng6JiCrQ1Dmusw=" "nixpkgs-terraform.cachix.org-1:8Sit092rIdAVENA3ZVeH9hzSiqI/jng6JiCrQ1Dmusw="
]; ];
trusted-users = [ "${username}" ]; trusted-users = [ "${username}" ];