Compare commits
4 commits
f04b07ce3b
...
d11a31ebcd
Author | SHA1 | Date | |
---|---|---|---|
d11a31ebcd | |||
5dc73f59e2 | |||
421064ce53 | |||
1b67f19e18 |
10 changed files with 112 additions and 39 deletions
|
@ -5,6 +5,12 @@ 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.
|
||||||
|
|
||||||
|
|
11
flake.nix
11
flake.nix
|
@ -137,17 +137,22 @@
|
||||||
"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 = {
|
||||||
"FORM3-CYRYLPLOTN" = darwin.lib.darwinSystem rec {
|
"airy" = darwin.lib.darwinSystem rec {
|
||||||
system = "x86_64-darwin";
|
system = "aarch64-darwin";
|
||||||
modules = [
|
modules = [
|
||||||
(./. + "/nixos/boxes/form3")
|
(./. + "/nixos/boxes/airy")
|
||||||
|
{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;
|
||||||
|
|
38
nixos/boxes/airy/default.nix
Normal file
38
nixos/boxes/airy/default.nix
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
{
|
||||||
|
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 = {
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,5 +1,8 @@
|
||||||
{ config, pkgs, ... }:
|
{
|
||||||
let
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
genericBackupPath = "/var/lib/backups/";
|
genericBackupPath = "/var/lib/backups/";
|
||||||
nixosContainersBackupPath = "/var/lib/nixos-containers/";
|
nixosContainersBackupPath = "/var/lib/nixos-containers/";
|
||||||
in rec {
|
in rec {
|
||||||
|
@ -40,8 +43,7 @@ in rec {
|
||||||
systemctl start --all mastodon*
|
systemctl start --all mastodon*
|
||||||
'';
|
'';
|
||||||
timerConfig = {OnCalendar = "daily";};
|
timerConfig = {OnCalendar = "daily";};
|
||||||
environmentFile =
|
environmentFile = "${config.sops.secrets.restic-backups-b2-environment.path}";
|
||||||
"${config.sops.secrets.restic-backups-b2-environment.path}";
|
|
||||||
exclude = ["cache"];
|
exclude = ["cache"];
|
||||||
pruneOpts = [
|
pruneOpts = [
|
||||||
"--keep-hourly 25"
|
"--keep-hourly 25"
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
{ config, pkgs, inputs, lib, system, ... }:
|
{
|
||||||
let
|
config,
|
||||||
|
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;
|
||||||
|
@ -26,8 +32,7 @@ let
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
imports =
|
imports = [../nginx.nix "${unstable}/nixos/modules/services/misc/forgejo.nix"];
|
||||||
[ ../nginx.nix "${unstable}/nixos/modules/services/misc/forgejo.nix" ];
|
|
||||||
disabledModules = ["services/misc/forgejo.nix"];
|
disabledModules = ["services/misc/forgejo.nix"];
|
||||||
|
|
||||||
inherit users;
|
inherit users;
|
||||||
|
|
|
@ -1,4 +1,8 @@
|
||||||
{ config, pkgs, ... }: {
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
console.keyMap = "pl2";
|
console.keyMap = "pl2";
|
||||||
imports = [./tailscale];
|
imports = [./tailscale];
|
||||||
services = {
|
services = {
|
||||||
|
|
|
@ -1,10 +1,15 @@
|
||||||
{ config, pkgs, ... }: {
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
services = {};
|
services = {};
|
||||||
|
|
||||||
xsession = {enable = false;};
|
xsession = {enable = false;};
|
||||||
|
|
||||||
home.sessionVariables = {QT_QPA_PLATFORM = "wayland";};
|
home.sessionVariables = {QT_QPA_PLATFORM = "wayland";};
|
||||||
home.packages = (with pkgs; [ gnome-usage gnome3.gnome-tweaks ])
|
home.packages =
|
||||||
|
(with pkgs; [gnome-usage gnome3.gnome-tweaks])
|
||||||
++ (with pkgs.gnomeExtensions; [
|
++ (with pkgs.gnomeExtensions; [
|
||||||
caffeine
|
caffeine
|
||||||
clipboard-indicator
|
clipboard-indicator
|
||||||
|
|
|
@ -1,4 +1,10 @@
|
||||||
{ 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
|
||||||
|
@ -16,7 +22,6 @@
|
||||||
bottom
|
bottom
|
||||||
curl
|
curl
|
||||||
dive
|
dive
|
||||||
dmidecode
|
|
||||||
dnsutils
|
dnsutils
|
||||||
docker-compose
|
docker-compose
|
||||||
du-dust
|
du-dust
|
||||||
|
@ -53,7 +58,6 @@
|
||||||
unzip
|
unzip
|
||||||
wget
|
wget
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
xdotool
|
inputs.nixpkgs-nixos-unstable.legacyPackages."${system}".yt-dlp
|
||||||
inputs.nixpkgs-nixos-unstable.legacyPackages."x86_64-linux".yt-dlp
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,6 +12,7 @@
|
||||||
atop
|
atop
|
||||||
btop
|
btop
|
||||||
btrfs-progs
|
btrfs-progs
|
||||||
|
dmidecode
|
||||||
glibcLocales
|
glibcLocales
|
||||||
hsetroot
|
hsetroot
|
||||||
lm_sensors
|
lm_sensors
|
||||||
|
@ -24,5 +25,6 @@
|
||||||
topgrade
|
topgrade
|
||||||
wirelesstools
|
wirelesstools
|
||||||
woeusb
|
woeusb
|
||||||
|
xdotool
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{ config, pkgs, ... }: {
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
services = {
|
services = {
|
||||||
|
|
||||||
kdeconnect.enable = true;
|
kdeconnect.enable = true;
|
||||||
kdeconnect.indicator = true;
|
kdeconnect.indicator = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
home.packages = [];
|
home.packages = [];
|
||||||
|
|
Loading…
Reference in a new issue