148 lines
3.7 KiB
Nix
148 lines
3.7 KiB
Nix
{
|
|
inputs,
|
|
outputs,
|
|
lib,
|
|
config,
|
|
pkgs,
|
|
...
|
|
}: {
|
|
imports = [
|
|
# If you want to use modules your own flake exports (from modules/home-manager):
|
|
# outputs.homeManagerModules.example
|
|
inputs.home-manager.nixosModules.home-manager
|
|
# Or modules exported from other flakes (such as nix-colors):
|
|
# inputs.nix-colors.homeManagerModules.default
|
|
|
|
# You can also split up your configuration and import pieces of it here:
|
|
# ./nvim.nix
|
|
./hardware-configuration.nix
|
|
./nextcloud.nix
|
|
];
|
|
|
|
nixpkgs = {
|
|
# You can add overlays here
|
|
overlays = [
|
|
# Add overlays your own flake exports (from overlays and pkgs dir):
|
|
outputs.overlays.additions
|
|
outputs.overlays.modifications
|
|
outputs.overlays.unstable-packages
|
|
|
|
# You can also add overlays exported from other flakes:
|
|
# neovim-nightly-overlay.overlays.default
|
|
|
|
# Or define it inline, for example:
|
|
# (final: prev: {
|
|
# hi = final.hello.overrideAttrs (oldAttrs: {
|
|
# patches = [ ./change-hello-to-hi.patch ];
|
|
# });
|
|
# })
|
|
];
|
|
# Configure your nixpkgs instance
|
|
config = {
|
|
# Disable if you don't want unfree packages
|
|
allowUnfree = true;
|
|
};
|
|
};
|
|
|
|
nix = {
|
|
gc = {
|
|
automatic = true;
|
|
dates = "weekly";
|
|
options = "--delete-older-than 7d";
|
|
};
|
|
# This will add each flake input as a registry
|
|
# To make nix3 commands consistent with your flake
|
|
registry = lib.mapAttrs (_: value: {flake = value;}) inputs;
|
|
|
|
# This will additionally add your inputs to the system's legacy channels
|
|
# Making legacy nix commands consistent as well, awesome!
|
|
nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry;
|
|
|
|
settings = {
|
|
# Enable flakes and new 'nix' command
|
|
experimental-features = "nix-command flakes";
|
|
# Deduplicate and optimize nix store
|
|
auto-optimise-store = true;
|
|
};
|
|
};
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
age
|
|
alejandra
|
|
git-filter-repo
|
|
home-manager
|
|
nextcloud
|
|
nginx
|
|
noto-fonts
|
|
noto-fonts-emoji-blob-bin
|
|
noto-fonts-emoji
|
|
oh-my-zsh
|
|
postgesql
|
|
rsync
|
|
wget
|
|
zsh
|
|
];
|
|
|
|
# Enable networking
|
|
networking.networkmanager.enable = true;
|
|
|
|
networking.firewall.allowedTCPPorts = [80 443];
|
|
|
|
# Set your time zone.
|
|
time.timeZone = "Europe/Amsterdam";
|
|
|
|
# Select internationalisation properties.
|
|
i18n.defaultLocale = "en_US.UTF-8";
|
|
|
|
i18n.extraLocaleSettings = {
|
|
LC_ADDRESS = "nl_NL.UTF-8";
|
|
LC_IDENTIFICATION = "nl_NL.UTF-8";
|
|
LC_MEASUREMENT = "nl_NL.UTF-8";
|
|
LC_MONETARY = "nl_NL.UTF-8";
|
|
LC_NAME = "nl_NL.UTF-8";
|
|
LC_NUMERIC = "nl_NL.UTF-8";
|
|
LC_PAPER = "nl_NL.UTF-8";
|
|
LC_TELEPHONE = "nl_NL.UTF-8";
|
|
LC_TIME = "nl_NL.UTF-8";
|
|
};
|
|
|
|
programs.zsh = {
|
|
enable = true;
|
|
};
|
|
|
|
security.acme = {
|
|
acceptTerms = true;
|
|
# Replace the email here!
|
|
email = "letsencrypt@gladtherescake.eu";
|
|
};
|
|
|
|
users.users = {
|
|
lillian = {
|
|
isNormalUser = true;
|
|
extraGroups = ["sudo" "networkmanager" "wheel" "vboxsf"];
|
|
shell = pkgs.zsh;
|
|
};
|
|
};
|
|
|
|
# Enable completion of system packages by zsh
|
|
environment.pathsToLink = ["/share/zsh"];
|
|
|
|
home-manager = {
|
|
extraSpecialArgs = {inherit inputs outputs;};
|
|
users = {
|
|
# Import your home-manager configuration
|
|
lillian = import ../../home-manager/queen-Lillian.nix;
|
|
};
|
|
};
|
|
|
|
networking.hostName = "queen";
|
|
|
|
#TODO: see if this bootloader works on the vps and if not replace it!
|
|
boot.loader.systemd-boot.enable = true;
|
|
boot.loader.systemd-boot.configurationLimit = 3;
|
|
boot.loader.efi.canTouchEfiVariables = true;
|
|
|
|
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
|
|
system.stateVersion = "23.05";
|
|
}
|