No description
- Nix 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
diff --git a/configuration.nix b/configuration.nix
index e05684a..6983062 100644
--- a/configuration.nix
+++ b/configuration.nix
@@ -2,58 +2,13 @@
config,
pkgs,
lib,
- modulesPath,
...
}:
{
imports = [
#inputs.disko.nixosModules.default
- {
- disko.devices = {
- disk = {
- my-disk = {
- device = "/dev/sda";
- type = "disk";
- content = {
- type = "gpt";
- partitions = {
- boot = {
- size = "1M";
- type = "EF02"; # for grub MBR
- };
- ESP = {
- type = "EF00";
- size = "512M";
- content = {
- type = "filesystem";
- format = "vfat";
- mountpoint = "/boot";
- mountOptions = [ "umask=0077" ];
- };
- };
-
- plainSwap = {
- size = "512M";
- content = {
- type = "swap";
- discardPolicy = "both";
- };
- };
- root = {
- size = "100%";
- content = {
- type = "filesystem";
- format = "xfs";
- mountpoint = "/";
- };
- };
- };
- };
- };
- };
- };
- }
- (modulesPath + "/profiles/qemu-guest.nix")
+ ./hardware.nix
+ ./network.nix
./remotebuild/remote-builder.nix
];
@@ -73,16 +28,6 @@
"vm.swappiness" = 20;
};
binfmt.emulatedSystems = [ "aarch64-linux" ];
- initrd = {
- availableKernelModules = [
- "ata_piix"
- "uhci_hcd"
- "virtio_pci"
- "virtio_scsi"
- "sd_mod"
- "sr_mod"
- ];
- };
};
services.resolved.enable = true;
@@ -107,9 +52,13 @@
"root"
"@wheel"
];
+ experimental-features = [
+ "nix-command"
+ "flakes"
+ #"pipe-operator"
+ ];
};
extraOptions = ''
- experimental-features = nix-command flakes #pipe-operator
use-xdg-base-directories = true
'';
gc = {
@@ -117,6 +66,7 @@
options = "--delete-older-than 7d";
randomizedDelaySec = "1h";
};
+ channel.enable = false;
};
services.journald.settings.Journal = {
@@ -124,26 +74,14 @@
SystemMaxUse = "256M";
};
- networking.useNetworkd = true;
- systemd.network.enable = true;
- systemd.network.networks."10-wan-addr" = {
- matchConfig.Name = "ens19";
- networkConfig = {
- Gateway = "2001:4ba0:92c1:9f::1";
- Address = "2001:4ba0:92c1:9f:2323::111/64";
- };
- };
time.timeZone = "UTC";
-
i18n.defaultLocale = "C.UTF-8";
programs.vim = {
enable = true;
defaultEditor = true;
};
- environment.systemPackages = [
-
- ];
+ environment.systemPackages = [ ];
security = {
sudo = {
execWheelOnly = true;
diff --git a/hardware.nix b/hardware.nix
new file mode 100644
index 0000000..67c9ddf
--- /dev/null
+++ b/hardware.nix
@@ -0,0 +1,63 @@
+{ config, lib, pkgs, modulesPath, ... }:
+
+{
+ imports = [
+ (modulesPath + "/profiles/qemu-guest.nix")
+ {
+ disko.devices = {
+ disk = {
+ my-disk = {
+ device = "/dev/sda";
+ type = "disk";
+ content = {
+ type = "gpt";
+ partitions = {
+ boot = {
+ size = "1M";
+ type = "EF02"; # for grub MBR
+ };
+ ESP = {
+ type = "EF00";
+ size = "512M";
+ content = {
+ type = "filesystem";
+ format = "vfat";
+ mountpoint = "/boot";
+ mountOptions = [ "umask=0077" ];
+ };
+ };
+
+ plainSwap = {
+ size = "512M";
+ content = {
+ type = "swap";
+ discardPolicy = "both";
+ };
+ };
+ root = {
+ size = "100%";
+ content = {
+ type = "filesystem";
+ format = "xfs";
+ mountpoint = "/";
+ };
+ };
+ };
+ };
+ };
+ };
+ };
+ }
+ ];
+
+ boot.initrd = {
+ availableKernelModules = [
+ "ata_piix"
+ "uhci_hcd"
+ "virtio_pci"
+ "virtio_scsi"
+ "sd_mod"
+ "sr_mod"
+ ];
+ };
+}
diff --git a/network.nix b/network.nix
new file mode 100644
index 0000000..096f52d
--- /dev/null
+++ b/network.nix
@@ -0,0 +1,18 @@
+{
+ ...
+}:
+
+{
+ networking.useNetworkd = true;
+
+ systemd.network = {
+ enable = true;
+ networks."10-wan-addr" = {
+ matchConfig.Name = "ens19";
+ networkConfig = {
+ Gateway = "2001:4ba0:92c1:9f::1";
+ Address = "2001:4ba0:92c1:9f:2323::111/64";
+ };
+ };
+ };
+}
|
||
| remotebuild | ||
| configuration.nix | ||
| flake.lock | ||
| flake.nix | ||
| hardware.nix | ||
| network.nix | ||