Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
Commit7362bf6744597d9d6215d49d1ba4881c2c34d4bc (patch)
Author
 Syndamia <kamen@syndamia.com>
2024-09-25 19:02:03 +0300
Committer
 Syndamia <kamen@syndamia.com>
2024-09-25 19:02:03 +0300
Files5d07287101ebb1cfd85811b8c5133ab57dabae09
nix-7362bf6744597d9d6215d49d1ba4881c2c34d4bc.tar
nix-7362bf6744597d9d6215d49d1ba4881c2c34d4bc.tar.gz
nix-7362bf6744597d9d6215d49d1ba4881c2c34d4bc.zip
Parent1ca182d0a51fe0fb9d06acc9db2be90943834e55 (diff)
feat(machines/cpx11-hel1): Added a very basic configuration for my server
diff --git a/machines/cpx11-hel1/configuration.nix b/machines/cpx11-hel1/configuration.nix
new file mode 100644
index 0000000..ddf19f9
--- /dev/null
+++ b/machines/cpx11-hel1/configuration.nix
@@ -0,0 +1,6 @@
+{ pkgs, ... }: {
+ environment.systemPackages = with pkgs; [
+ ];
+
+ networking.firewall.enable = true;
+}
diff --git a/machines/cpx11-hel1/hardware-configuration.nix b/machines/cpx11-hel1/hardware-configuration.nix
new file mode 100644
index 0000000..84f7e12
--- /dev/null
+++ b/machines/cpx11-hel1/hardware-configuration.nix
@@ -0,0 +1,37 @@
+# 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 = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
+ boot.initrd.kernelModules = [ ];
+ boot.kernelModules = [ "kvm-amd" ];
+ boot.extraModulePackages = [ ];
+
+ fileSystems."/" =
+ { device = "/dev/disk/by-uuid/3a9fb168-635b-4e85-8bd6-d6e592361870";
+ fsType = "ext4";
+ };
+
+ fileSystems."/boot" =
+ { device = "/dev/disk/by-uuid/6621-89DB";
+ fsType = "vfat";
+ };
+
+ swapDevices = [ ];
+
+ # 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.enp4s0.useDHCP = lib.mkDefault true;
+
+ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
+ hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
+}
diff --git a/machines/cpx11-hel1/sysidentity.nix b/machines/cpx11-hel1/sysidentity.nix
new file mode 100644
index 0000000..cc057a6
--- /dev/null
+++ b/machines/cpx11-hel1/sysidentity.nix
@@ -0,0 +1,7 @@
+groups: {
+ name = "cpx11-hel1";
+ arch = "x86_64-linux";
+ kind = "server";
+
+ include = groups.barebones;
+}
diff --git a/modules/server/cli-essential.nix b/modules/server/cli-essential.nix
new file mode 120000
index 0000000..13e8cc9
--- /dev/null
+++ b/modules/server/cli-essential.nix
@@ -0,0 +1 @@
+../personal/cli-essential.nix \ No newline at end of file
diff --git a/modules/server/default.nix b/modules/server/default.nix
new file mode 120000
index 0000000..aa9c0e0
--- /dev/null
+++ b/modules/server/default.nix
@@ -0,0 +1 @@
+../personal/default.nix \ No newline at end of file
diff --git a/modules/server/fonts.nix b/modules/server/fonts.nix
new file mode 120000
index 0000000..9bd6055
--- /dev/null
+++ b/modules/server/fonts.nix
@@ -0,0 +1 @@
+../personal/fonts.nix \ No newline at end of file
diff --git a/modules/server/users-standard.nix b/modules/server/users-standard.nix
new file mode 100644
index 0000000..7cbe2a6
--- /dev/null
+++ b/modules/server/users-standard.nix
@@ -0,0 +1,11 @@
+{ config, pkgs, ... }: {
+ users = {
+ users.admin = {
+ isNormalUser = true;
+ extraGroups = [ "wheel" "libvirtd" "plugdev" "docker" ];
+ packages = [ ];
+ # shell = pkgs.zsh;
+ # homeMode = "711"; # mostly done for httpd access
+ };
+ };
+}