This commit is contained in:
arouzing 2023-02-01 03:11:48 -05:00
parent 076814d4b9
commit 3c4acde325
8 changed files with 104 additions and 21 deletions

View file

@ -1,12 +1,13 @@
{config, lib, pkgs, modulesPath, ... }: {config, lib, pkgs, modulesPath, ... }:
{ {
system.stateVersion = "22.11";
imports = imports =
[ (modulesPath + "/installer/scan/not-detected.nix") [ (modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "usbhid" "sd_mod" "sdhci_pci" ]; # boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "usbhid" "sd_mod" "sdhci_pci" ];
boot.initrd.kernelModules = [ "dm-snapshot" ]; # boot.initrd.kernelModules = [ "dm-snapshot" ];
boot.kernelModules = [ "kvm-intel" "wl" ]; # boot.kernelModules = [ "kvm-intel" "wl" ];
# boot.extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ]; # boot.extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ];
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; # hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -1,4 +1,4 @@
_: { config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
virtualisation.docker = { virtualisation.docker = {
enable = true; enable = true;

View file

@ -1,7 +1,7 @@
_: { config, pkgs, lib, ... }: _: { config, pkgs, lib, ... }:
{ {
services.openssh = lib.mkDefault{ services.openssh = {
enable = true; enable = true;
openFirewall = true; openFirewall = true;
startWhenNeeded = true; startWhenNeeded = true;

View file

@ -1,4 +1,4 @@
_: { config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
users.users.arouzing = { users.users.arouzing = {
isNormalUser = true; isNormalUser = true;

79
flake.lock generated Normal file
View file

@ -0,0 +1,79 @@
{
"nodes": {
"nixlib": {
"locked": {
"lastModified": 1636849918,
"narHash": "sha256-nzUK6dPcTmNVrgTAC1EOybSMsrcx+QrVPyqRdyKLkjA=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "28a5b0557f14124608db68d3ee1f77e9329e9dd5",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixpkgs.lib",
"type": "github"
}
},
"nixos-generators": {
"inputs": {
"nixlib": "nixlib",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1674666581,
"narHash": "sha256-KNI2s/xrL7WOYaPJAWKBtb7cCH3335rLfsL+B+ssuGY=",
"owner": "nix-community",
"repo": "nixos-generators",
"rev": "6a5dc1d3d557ea7b5c19b15ff91955124d0400fa",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixos-generators",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1675153841,
"narHash": "sha256-EWvU3DLq+4dbJiukfhS7r6sWZyJikgXn6kNl7eHljW8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "ea692c2ad1afd6384e171eabef4f0887d2b882d3",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"nixpkgs-small": {
"locked": {
"lastModified": 1675154384,
"narHash": "sha256-gUXzyTS3WsO3g2Rz0qOYR2a26whkyL2UfTr1oPH9mm8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "0218941ea68b4c625533bead7bbb94ccce52dceb",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-22.11",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"nixos-generators": "nixos-generators",
"nixpkgs": "nixpkgs",
"nixpkgs-small": "nixpkgs-small"
}
}
},
"root": "root",
"version": 7
}

View file

@ -6,15 +6,15 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
}; };
outputs = { self, nixpkgs, ... }@inputs: outputs = { self, nixos-generators, nixpkgs, ... }@inputs:
{ {
example = nixos-generators.nixosGenerate { example = nixos-generators.nixosGenerate {
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules = [
./hosts/example.nix ./hosts/example.nix
]; ];
format = "qcow"; format = "virtualbox";
}; };
apps."x86_64-linux".default = lollypops.apps."x86_64-linux".default { configFlake = self; };
}; };
} }

View file

@ -3,15 +3,17 @@
{ {
imports = imports =
[ # Include the results of the hardware scan. [ # Include the results of the hardware scan.
./.modules/base/hardware.nix # ../.modules/base/hardware.nix
./.modules/services/docker.nix # ../.modules/services/docker.nix
./.modules/arouzing.nix ../.modules/users/arouzing.nix
../.modules/services/openssh.nix
]; ];
# base packages # base packages
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
htop htop
vim vim
# sleep
# tailscale # tailscale
]; ];
@ -21,17 +23,17 @@
networkmanager.enable = true; networkmanager.enable = true;
}; };
services.tailscale.enable = true; # services.tailscale.enable = true;
time.timeZone = "America/New_York"; time.timeZone = "America/New_York";
# Open ports in the firewall. # Open ports in the firewall.
networking.firewall = { # networking.firewall = {
enable = true; # enable = true;
allowedTCPPorts = []; # allowedTCPPorts = [];
allowedUDPPorts = []; # allowedUDPPorts = [];
}; # };
## main services ## main services
system.stateVersion = "22.11";
} }

1
result Symbolic link
View file

@ -0,0 +1 @@
/nix/store/yjmyc0nj40qmc35b63mwkgsnhhrbm3yb-nixos-ova-23.05.20230131.ea692c2-x86_64-linux