Compare commits

..

No commits in common. "d11a31ebcd74573a0dfdb2a1d1562de114cb603d" and "f04b07ce3b83c170d92e9ead3e0cb9e32196539c" have entirely different histories.

10 changed files with 39 additions and 112 deletions

View file

@ -5,12 +5,6 @@ My dotfiles - including my vim, terminal and font config.
My current setup consists of multiple machines running NixOS. My current setup consists of multiple machines running NixOS.
This is using flakes for reproducibility and home manager for setting up user-specific things. This is using flakes for reproducibility and home manager for setting up user-specific things.
## generating ssh keys
```
ssh-keygen -t ed25519
```
Workstations are set up by running ` sudo nixos-rebuild switch --flake '.#'` and servers are by `nixos-rebuild switch --flake '.#servername' --target-host root@hostname`. Workstations are set up by running ` sudo nixos-rebuild switch --flake '.#'` and servers are by `nixos-rebuild switch --flake '.#servername' --target-host root@hostname`.
I don't use home manager the program, everything is referenced from the top flake. I don't use home manager the program, everything is referenced from the top flake.

View file

@ -137,22 +137,17 @@
"x86_64-linux".default = mkShell nixpkgs-stable "x86_64-linux"; "x86_64-linux".default = mkShell nixpkgs-stable "x86_64-linux";
"aarch64-linux".default = mkShell nixpkgs-stable "aarch64-linux"; "aarch64-linux".default = mkShell nixpkgs-stable "aarch64-linux";
}; };
# Expose the package set, including overlays, for convenience.
darwinPackages = self.darwinConfigurations."airy".pkgs;
darwinConfigurations = { darwinConfigurations = {
"airy" = darwin.lib.darwinSystem rec { "FORM3-CYRYLPLOTN" = darwin.lib.darwinSystem rec {
system = "aarch64-darwin"; system = "x86_64-darwin";
modules = [ modules = [
(./. + "/nixos/boxes/airy") (./. + "/nixos/boxes/form3")
{users.users.cyryl.home = "/Users/cyryl";}
home-manager.darwinModules.home-manager home-manager.darwinModules.home-manager
{ {
home-manager = { home-manager = {
useGlobalPkgs = true; useGlobalPkgs = true;
useUserPackages = true; useUserPackages = true;
users.cyryl = { users.cyryl = {
home.homeDirectory = "/Users/cyryl";
imports = [./nixos/home-manager]; imports = [./nixos/home-manager];
_module.args.inputs = inputs; _module.args.inputs = inputs;
_module.args.system = system; _module.args.system = system;

View file

@ -1,38 +0,0 @@
{
config,
pkgs,
inputs,
lib,
nixpkgs-nixos-unstable-and-unfree,
...
}: {
imports = [
../../git
../../helix
../../mercurial
../../vim
../../zsh
];
services.nix-daemon.enable = true;
nix.settings.experimental-features = "nix-command flakes";
programs.zsh.enable = true; # default shell on catalina
system.stateVersion = 4;
# The platform the configuration will be used on.
nixpkgs.hostPlatform = "aarch64-darwin";
homebrew.enable = true;
homebrew.casks = ["firefox"];
home-manager.users.cyryl = {...}: {
imports = [
../../home-manager/programs/kitty.nix
];
home.packages = with pkgs; [];
programs = {
};
};
}

View file

@ -1,12 +1,9 @@
{ { config, pkgs, ... }:
config, let
pkgs,
...
}: let
genericBackupPath = "/var/lib/backups/"; genericBackupPath = "/var/lib/backups/";
nixosContainersBackupPath = "/var/lib/nixos-containers/"; nixosContainersBackupPath = "/var/lib/nixos-containers/";
in rec { in rec {
environment.systemPackages = with pkgs; [restic]; environment.systemPackages = with pkgs; [ restic ];
sops.secrets."restic-backups-b2-repo-password" = { sops.secrets."restic-backups-b2-repo-password" = {
sopsFile = ./restic.sops.yaml; sopsFile = ./restic.sops.yaml;
@ -42,9 +39,10 @@ in rec {
systemctl start container@foundryvtt.service systemctl start container@foundryvtt.service
systemctl start --all mastodon* systemctl start --all mastodon*
''; '';
timerConfig = {OnCalendar = "daily";}; timerConfig = { OnCalendar = "daily"; };
environmentFile = "${config.sops.secrets.restic-backups-b2-environment.path}"; environmentFile =
exclude = ["cache"]; "${config.sops.secrets.restic-backups-b2-environment.path}";
exclude = [ "cache" ];
pruneOpts = [ pruneOpts = [
"--keep-hourly 25" "--keep-hourly 25"
"--keep-daily 8" "--keep-daily 8"
@ -52,7 +50,7 @@ in rec {
"--keep-monthly 13" "--keep-monthly 13"
"--keep-yearly 2" "--keep-yearly 2"
]; ];
checkOpts = ["--with-cache"]; checkOpts = [ "--with-cache" ];
}; };
}; };

View file

@ -1,11 +1,5 @@
{ { config, pkgs, inputs, lib, system, ... }:
config, let
pkgs,
inputs,
lib,
system,
...
}: let
unstable = inputs.nixpkgs-nixos-unstable; unstable = inputs.nixpkgs-nixos-unstable;
package = unstable.legacyPackages."${system}".forgejo; package = unstable.legacyPackages."${system}".forgejo;
httpPort = 8083; httpPort = 8083;
@ -28,19 +22,20 @@
}; };
groups."${systemGroupName}" = { groups."${systemGroupName}" = {
inherit gid; inherit gid;
members = ["${systemUserName}" "nginx"]; members = [ "${systemUserName}" "nginx" ];
}; };
}; };
in { in {
imports = [../nginx.nix "${unstable}/nixos/modules/services/misc/forgejo.nix"]; imports =
disabledModules = ["services/misc/forgejo.nix"]; [ ../nginx.nix "${unstable}/nixos/modules/services/misc/forgejo.nix" ];
disabledModules = [ "services/misc/forgejo.nix" ];
inherit users; inherit users;
boot.kernel.sysctl = {"net.ipv4.ip_unprivileged_port_start" = 0;}; boot.kernel.sysctl = { "net.ipv4.ip_unprivileged_port_start" = 0; };
systemd.services.systemd-sysctl.enable = lib.mkForce true; systemd.services.systemd-sysctl.enable = lib.mkForce true;
networking.firewall.allowedTCPPorts = [sshPort]; networking.firewall.allowedTCPPorts = [ sshPort ];
services.nginx = { services.nginx = {
virtualHosts = { virtualHosts = {
"${domain}" = { "${domain}" = {

View file

@ -1,12 +1,8 @@
{ { config, pkgs, ... }: {
config,
pkgs,
...
}: {
console.keyMap = "pl2"; console.keyMap = "pl2";
imports = [./tailscale]; imports = [ ./tailscale ];
services = { services = {
udev.packages = [pkgs.android-udev-rules]; udev.packages = [ pkgs.android-udev-rules ];
ratbagd.enable = true; ratbagd.enable = true;
gvfs.enable = true; gvfs.enable = true;

View file

@ -1,15 +1,10 @@
{ { config, pkgs, ... }: {
config, services = { };
pkgs,
...
}: {
services = {};
xsession = {enable = false;}; xsession = { enable = false; };
home.sessionVariables = {QT_QPA_PLATFORM = "wayland";}; home.sessionVariables = { QT_QPA_PLATFORM = "wayland"; };
home.packages = home.packages = (with pkgs; [ gnome-usage gnome3.gnome-tweaks ])
(with pkgs; [gnome-usage gnome3.gnome-tweaks])
++ (with pkgs.gnomeExtensions; [ ++ (with pkgs.gnomeExtensions; [
caffeine caffeine
clipboard-indicator clipboard-indicator
@ -19,7 +14,7 @@
dconf.settings = { dconf.settings = {
"org/gnome/mutter" = { "org/gnome/mutter" = {
# https://github.com/NixOS/nixpkgs/issues/114514#issuecomment-1177709271 # https://github.com/NixOS/nixpkgs/issues/114514#issuecomment-1177709271
experimental-features = ["scale-monitor-framebuffer"]; experimental-features = [ "scale-monitor-framebuffer" ];
}; };
"org/gnome/shell" = { "org/gnome/shell" = {
disable-user-extensions = false; disable-user-extensions = false;

View file

@ -1,10 +1,4 @@
{ { config, pkgs, inputs, system, ... }: {
config,
pkgs,
inputs,
system,
...
}: {
home.packages = with pkgs; [ home.packages = with pkgs; [
(pass.withExtensions (ext: [ (pass.withExtensions (ext: [
ext.pass-otp ext.pass-otp
@ -22,6 +16,7 @@
bottom bottom
curl curl
dive dive
dmidecode
dnsutils dnsutils
docker-compose docker-compose
du-dust du-dust
@ -58,6 +53,7 @@
unzip unzip
wget wget
wl-clipboard wl-clipboard
inputs.nixpkgs-nixos-unstable.legacyPackages."${system}".yt-dlp xdotool
inputs.nixpkgs-nixos-unstable.legacyPackages."x86_64-linux".yt-dlp
]; ];
} }

View file

@ -12,7 +12,6 @@
atop atop
btop btop
btrfs-progs btrfs-progs
dmidecode
glibcLocales glibcLocales
hsetroot hsetroot
lm_sensors lm_sensors
@ -25,6 +24,5 @@
topgrade topgrade
wirelesstools wirelesstools
woeusb woeusb
xdotool
]; ];
} }

View file

@ -1,13 +1,11 @@
{ { config, pkgs, ... }: {
config,
pkgs,
...
}: {
services = { services = {
kdeconnect.enable = true; kdeconnect.enable = true;
kdeconnect.indicator = true; kdeconnect.indicator = true;
}; };
home.packages = []; home.packages = [ ];
dconf.settings = {}; dconf.settings = { };
} }