-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
194 additions
and
35 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
{ config, pkgs, ... }: | ||
|
||
{ | ||
imports = [ | ||
# hardware config | ||
./chuwi.hardware.nix | ||
|
||
# Modules | ||
./mods/tailscale.nix | ||
]; | ||
|
||
# Enable flakes | ||
nix.settings.experimental-features = [ "nix-command" "flakes" ]; | ||
|
||
# Bootloader | ||
boot = { | ||
loader.systemd-boot.enable = true; | ||
loader.efi.canTouchEfiVariables = true; | ||
}; | ||
|
||
# Enable networking | ||
networking = { | ||
hostName = "chuwi"; | ||
networkmanager.enable = true; | ||
}; | ||
|
||
# Time zone & locale | ||
time.timeZone = "Europe/Oslo"; | ||
i18n.defaultLocale = "en_US.UTF-8"; | ||
|
||
# Enable the X11 windowing system. | ||
services.xserver.enable = true; | ||
|
||
# Enable the GNOME Desktop Environment. | ||
services.xserver.displayManager.gdm.enable = true; | ||
services.xserver.desktopManager.gnome.enable = true; | ||
|
||
# Configure keymap in X11 | ||
services.xserver.xkb = { | ||
layout = "no"; | ||
variant = ""; | ||
}; | ||
|
||
# Enable sound with pipewire. | ||
hardware.pulseaudio.enable = false; | ||
security.rtkit.enable = true; | ||
services.pipewire = { | ||
enable = true; | ||
alsa.enable = true; | ||
alsa.support32Bit = true; | ||
pulse.enable = true; | ||
# If you want to use JACK applications, uncomment this | ||
#jack.enable = true; | ||
|
||
# use the example session manager (no others are packaged yet so this is enabled by default, | ||
# no need to redefine it in your config for now) | ||
#media-session.enable = true; | ||
}; | ||
|
||
# Enable touchpad support (enabled default in most desktopManager). | ||
# services.xserver.libinput.enable = true; | ||
|
||
# Define a user account. Don't forget to set a password with ‘passwd’. | ||
users.users.knarf = { | ||
isNormalUser = true; | ||
description = "knarf"; | ||
extraGroups = [ | ||
"networkmanager" | ||
"wheel" | ||
"docker" | ||
"audio" | ||
"seat" # seatd group | ||
"incus-admin" | ||
"incus" | ||
]; | ||
packages = with pkgs; []; | ||
shell = pkgs.zsh; | ||
}; | ||
|
||
# List packages installed in system profile. To search, run: | ||
# $ nix search wget | ||
environment.systemPackages = with pkgs; [ | ||
vim | ||
wget | ||
git | ||
tmux | ||
bash | ||
home-manager | ||
zsh | ||
pciutils | ||
gnumake | ||
]; | ||
|
||
programs.zsh.enable = true; | ||
programs.firefox.enable = true; | ||
|
||
# Enable the OpenSSH daemon. | ||
services.openssh.enable = true; | ||
|
||
# This value determines the NixOS release from which the default | ||
# settings for stateful data, like file locations and database versions | ||
# on your system were taken. It‘s perfectly fine and recommended to leave | ||
# this value at the release version of the first install of this system. | ||
# Before changing this value read the documentation for this option | ||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). | ||
system.stateVersion = "24.05"; # Did you read the comment? | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# 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 = [ "xhci_pci" "ahci" "usb_storage" "sd_mod" "sdhci_pci" ]; | ||
boot.initrd.kernelModules = [ ]; | ||
boot.kernelModules = [ "kvm-intel" ]; | ||
boot.extraModulePackages = [ ]; | ||
|
||
fileSystems."/" = | ||
{ device = "/dev/disk/by-uuid/dc4a9bdf-fd39-4f82-b331-8c32aaa544b5"; | ||
fsType = "ext4"; | ||
}; | ||
|
||
fileSystems."/boot" = | ||
{ device = "/dev/disk/by-uuid/32C9-4CD0"; | ||
fsType = "vfat"; | ||
options = [ "fmask=0022" "dmask=0022" ]; | ||
}; | ||
|
||
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.wlp0s20f3.useDHCP = lib.mkDefault true; | ||
|
||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; | ||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters