generation 503 25.11.20250714.62e0f05
This commit is contained in:
@@ -17,6 +17,9 @@ in {
|
|||||||
kompose
|
kompose
|
||||||
kubectl
|
kubectl
|
||||||
kubernetes
|
kubernetes
|
||||||
|
openssl
|
||||||
|
cfssl
|
||||||
|
certmgr
|
||||||
];
|
];
|
||||||
|
|
||||||
services.kubernetes = {
|
services.kubernetes = {
|
||||||
|
|||||||
54
flake.nix
54
flake.nix
@@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
@@ -16,7 +17,6 @@
|
|||||||
|
|
||||||
nixpkgs-clisp.url = "github:NixOS/nixpkgs/da320e5472f021b96a883f71fc525ca0e4815273";
|
nixpkgs-clisp.url = "github:NixOS/nixpkgs/da320e5472f021b96a883f71fc525ca0e4815273";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs = {
|
||||||
self,
|
self,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
@@ -26,59 +26,37 @@
|
|||||||
nixpkgs-clisp,
|
nixpkgs-clisp,
|
||||||
} @ inputs: let
|
} @ inputs: let
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
|
|
||||||
|
# hostnames
|
||||||
|
hosts = ["thonkpad" "rq" "yoga" "server1" "server2" "server3"];
|
||||||
|
|
||||||
baseModule = {lib, ...}: {
|
baseModule = {lib, ...}: {
|
||||||
imports = [
|
imports = [
|
||||||
home-manager.nixosModules.default
|
home-manager.nixosModules.default
|
||||||
agenix.nixosModules.default
|
agenix.nixosModules.default
|
||||||
];
|
];
|
||||||
|
|
||||||
system.configurationRevision = lib.mkIf (self ? rev) self.rev;
|
system.configurationRevision = lib.mkIf (self ? rev) self.rev;
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
nixpkgs.overlays = [
|
||||||
emacs-overlay.overlay
|
emacs-overlay.overlay
|
||||||
(final: _prev: {
|
(final: _prev: {
|
||||||
clisp = nixpkgs-clisp.legacyPackages.${system}.clisp;
|
clisp = nixpkgs-clisp.legacyPackages.${system}.clisp;
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
agenix.packages.${system}.default
|
agenix.packages.${system}.default
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
mkHost = name: {
|
||||||
|
name = name;
|
||||||
|
value = nixpkgs.lib.nixosSystem {
|
||||||
|
modules = [
|
||||||
|
baseModule
|
||||||
|
./hosts/${name}/configuration.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
nixosConfigurations.thonkpad = nixpkgs.lib.nixosSystem {
|
nixosConfigurations = builtins.listToAttrs (map mkHost hosts);
|
||||||
modules = [
|
|
||||||
baseModule
|
|
||||||
./hosts/thonkpad/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nixosConfigurations.server = nixpkgs.lib.nixosSystem {
|
|
||||||
modules = [
|
|
||||||
baseModule
|
|
||||||
./hosts/server/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nixosConfigurations.server-gpu = nixpkgs.lib.nixosSystem {
|
|
||||||
modules = [
|
|
||||||
baseModule
|
|
||||||
./hosts/server-gpu/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nixosConfigurations.rq = nixpkgs.lib.nixosSystem {
|
|
||||||
modules = [
|
|
||||||
baseModule
|
|
||||||
./hosts/rq/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nixosConfigurations.yoga = nixpkgs.lib.nixosSystem {
|
|
||||||
modules = [
|
|
||||||
baseModule
|
|
||||||
./hosts/yoga/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -150,6 +150,14 @@ in {
|
|||||||
name = "grfp";
|
name = "grfp";
|
||||||
url = "https://www.research.gov/grfp/Login.do"; # your tax dollars fund my phd loser. pay big sam up.
|
url = "https://www.research.gov/grfp/Login.do"; # your tax dollars fund my phd loser. pay big sam up.
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
name = "cmueats";
|
||||||
|
url = "https://cmueats.com/";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
name = "cmucourses";
|
||||||
|
url = "https://cmucourses.com/";
|
||||||
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
|
|||||||
25
home/scripts/rebuild-nocommit.sh
Normal file
25
home/scripts/rebuild-nocommit.sh
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
# blatently adapted from: https://gist.github.com/0atman/1a5133b842f929ba4c1e195ee67599d5
|
||||||
|
|
||||||
|
# set -e
|
||||||
|
|
||||||
|
# cd to your config dir
|
||||||
|
pushd /home/synchronous/nix-cfg
|
||||||
|
|
||||||
|
# early return if no changes are given
|
||||||
|
git --git-dir /home/synchronous/nix-cfg/.git add .
|
||||||
|
if git --git-dir /home/synchronous/nix-cfg/.git diff-index --quiet HEAD; then
|
||||||
|
echo "No changes detected, exiting."
|
||||||
|
popd
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Autoformat your nix files
|
||||||
|
alejandra . &>/dev/null \
|
||||||
|
|| ( alejandra . ; echo "formatting failed!" && exit 1)
|
||||||
|
|
||||||
|
prev=$(hostname)
|
||||||
|
|
||||||
|
sudo /run/current-system/sw/bin/nixos-rebuild switch --flake /home/synchronous/nix-cfg/flake.nix#"$prev" 2>&1 | tee /tmp/nixos-switch.log
|
||||||
|
|
||||||
|
notify-send -e "NixOS Rebuilt OK!" --icon=software-update-available
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
networking.hostName = "server"; # Define your hostname.
|
networking.hostName = "server1"; # Define your hostname.
|
||||||
res = "2560x1440";
|
res = "2560x1440";
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
36
hosts/server2/configuration.nix
Normal file
36
hosts/server2/configuration.nix
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
./hardware-configuration.nix
|
||||||
|
../../system/system.nix
|
||||||
|
../meta.nix
|
||||||
|
../../extras/ssh.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
config = {
|
||||||
|
networking.hostName = "server2"; # Define your hostname.
|
||||||
|
res = "2560x1440";
|
||||||
|
|
||||||
|
home-manager = {
|
||||||
|
useGlobalPkgs = true;
|
||||||
|
useUserPackages = true;
|
||||||
|
backupFileExtension = "backup";
|
||||||
|
users.synchronous.imports = [../../home/home.nix];
|
||||||
|
};
|
||||||
|
|
||||||
|
# Bootloader.
|
||||||
|
# boot.loader.grub.enable = true;
|
||||||
|
# boot.loader.grub.device = "/dev/nvme0n1";
|
||||||
|
# boot.loader.grub.useOSProber = true;
|
||||||
|
# boot.loader.grub.version = 2;
|
||||||
|
# services.logind.lidSwitchExternalPower = "ignore";
|
||||||
|
|
||||||
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
boot.loader.grub.enable = false;
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
networking.hostName = "server-gpu"; # Define your hostname.
|
networking.hostName = "server3-gpu"; # Define your hostname.
|
||||||
res = "2560x1440";
|
res = "2560x1440";
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
Reference in New Issue
Block a user