This commit is contained in:
Leon Liu 2023-11-09 15:34:43 +09:00
parent b1e6779a05
commit 0a80a57f70
2 changed files with 10 additions and 5 deletions

View File

@ -5,7 +5,7 @@
{ config, pkgs, ... }:
let
kubeMasterIP = "192.168.3.56";
kubeMasterIP = "192.168.11.2";
kubeMasterHostname = "api.kube";
kubeMasterAPIServerPort = 6443;
in
@ -15,7 +15,8 @@ in
./hardware-configuration.nix
./containers.nix
];
nix.settings.trusted-users = [ "root" "liu" ];
virtualisation.docker.enable = true;
nix.settings.experimental-features = [ "nix-command" "flakes" ];
networking.extraHosts = "${kubeMasterIP} ${kubeMasterHostname}";
# Bootloader.
@ -107,8 +108,9 @@ in
isNormalUser = true;
shell = pkgs.zsh;
description = "Leon Liu";
extraGroups = [ "networkmanager" "wheel" ];
extraGroups = [ "networkmanager" "wheel" "docker" ];
};
users.extraGroups.docker.members = [ "liu" ];
fonts = {
fontDir.enable = true;
@ -154,6 +156,7 @@ in
kompose
kubectl
kubernetes
argocd
];
# Some programs need SUID wrappers, can be configured further or are
@ -175,6 +178,7 @@ in
apiserver = {
securePort = kubeMasterAPIServerPort;
advertiseAddress = kubeMasterIP;
allowPrivileged = true;
};
easyCerts = true;
@ -189,6 +193,7 @@ in
# Or disable the firewall altogether.
networking.firewall.enable = false;
services.tailscale.enable = true;
services.adguardhome.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. Its perfectly fine and recommended to leave

View File

@ -43,8 +43,6 @@
google-chrome
guake
dmidecode
jetbrains.rust-rover
qbittorrent
];
# Home Manager is pretty good at managing dotfiles. The primary way to manage
@ -103,6 +101,7 @@
initExtra = ''
VISUAL=vim
EDITOR="$VISUAL"
PATH=$PATH:$HOME/.cargo/bin/
'';
};
@ -116,6 +115,7 @@
enable = true;
extensions = [
pkgs.vscode-extensions.bbenoist.nix
pkgs.vscode-extensions.rust-lang.rust-analyzer
];
userSettings = {
"window.zoomLevel" = 2;