Clean up nixos

This commit is contained in:
Ariel Sosnovsky committed 2024-03-21 10:27:40 -04:00
1 parent b1be2d7bc1
commit b04f7d502a
8 files changed
+14 -119

No files matched your search

-13
View File
@@ -1,13 +0,0 @@
{ ... }:
{
imports =
[
./hardware-configuration.nix
(import ./main.nix {
hostName = "";
stateVersion = "23.05";
dbConnectionStr = "";
K3SToken = "";
})
];
}
-37
View File
@@ -1,37 +0,0 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{
hostName,
dbConnectionStr,
K3SToken
}:
{ config, pkgs, ... }:
{
# Bootloader.
boot.initrd = {
supportedFilesystems = [ "nfs" ];
kernelModules = [ "nfs" ];
};
i18n.defaultLocale = "en_CA.UTF-8";
services.nfs.server.enable = true;
services.rpcbind.enable = true;
environment.systemPackages = with pkgs; [
k3s
nfs-utils
git
rocmPackages.rocm-smi
rocmPackages.rpp
];
services.k3s.enable = true;
services.k3s.role = "server";
services.k3s.extraFlags = toString [
"--tls-san"
hostName
"--datastore-endpoint" dbConnectionStr
"--token" K3SToken
];
networking.firewall.allowedTCPPorts = [ 22 80 443 ];
networking.firewall.allowedUDPPorts = [ 80 443 ];
}
-23
View File
@@ -1,23 +0,0 @@
{
hostName,
stateVersion,
dbConnectionStr,
K3SToken
}:
{ config, pkgs, ... }:
{
imports =
[
(import ./k3s.nix {
hostName = hostName;
dbConnectionStr = dbConnectionStr;
K3SToken = K3SToken;
})
./users.nix
./settings.nix
];
# Bootloader.
networking.hostName = hostName;
system.stateVersion = stateVersion;
}
-19
View File
@@ -1,19 +0,0 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, ... }:
{
# Bootloader.
networking.networkmanager.enable = true;
time.timeZone = "America/Toronto";
i18n.defaultLocale = "en_CA.UTF-8";
services.xserver = {
layout = "us";
xkbVariant = "";
};
nixpkgs.config.allowUnfree = true;
services.openssh.enable = true;
networking.firewall.enable = false;
}
-21
View File
@@ -1,21 +0,0 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, ... }:
{
users.users.ari = {
isNormalUser = true;
description = "Ari";
extraGroups = [ "networkmanager" "wheel" "root" ];
packages = with pkgs; [];
};
environment.systemPackages = with pkgs; [
pciutils
usbutils
jq
];
}
+7
View File
@@ -0,0 +1,7 @@
{ config, pkgs, ... }:
{
environment.systemPackages = with pkgs; [
rocmPackages.rocm-smi
rocmPackages.rpp
];
}
+7 -5
View File
@@ -4,7 +4,7 @@
{
hostName,
dbConnectionStr,
K3SToken,
K3SToken
}:
{ config, pkgs, ... }:
@@ -17,10 +17,12 @@
i18n.defaultLocale = "en_CA.UTF-8";
services.nfs.server.enable = true;
services.rpcbind.enable = true;
environment.systemPackages = [
pkgs.k3s
pkgs.nfs-utils
pkgs.git
environment.systemPackages = with pkgs; [
k3s
nfs-utils
git
rocmPackages.rocm-smi
rocmPackages.rpp
];
services.k3s.enable = true;
services.k3s.role = "server";
-1
View File
@@ -3,7 +3,6 @@
stateVersion,
dbConnectionStr,
K3SToken,
additionalPkgs = [],
}:
{ config, pkgs, ... }:
{