Compare commits

..

No commits in common. "4cd0f83ce88a5c3d22abbb642275a2c0ac6a5c92" and "3594e5479d24aff31d859d865c1345cca834ff6c" have entirely different histories.

130 changed files with 1699 additions and 2360 deletions

66
flake.lock generated
View file

@ -124,11 +124,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1707095972, "lastModified": 1706491084,
"narHash": "sha256-iQ2jpCCwYWpk4UcPEgQqRSOVsY2p8GkPmz/lJw47Cvo=", "narHash": "sha256-eaEv+orTmr2arXpoE4aFZQMVPOYXCBEbLgK22kOtkhs=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "2e9b88f02ec166b1c3f0a638688f8e4ef444de32", "rev": "f67ba6552845ea5d7f596a24d57c33a8a9dc8de9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -148,11 +148,11 @@
"nixpkgs-stable": "nixpkgs-stable_2" "nixpkgs-stable": "nixpkgs-stable_2"
}, },
"locked": { "locked": {
"lastModified": 1707099004, "lastModified": 1706777546,
"narHash": "sha256-O5LZdwF6QL6Vt8RVnmtiYIt0ZD/vhwnHf2k4sHG8xog=", "narHash": "sha256-ZOsu6wxxNXm5o6RfXTcsDHiTtXf6fxCeEEpu73RJVh0=",
"owner": "nix-community", "owner": "nix-community",
"repo": "emacs-overlay", "repo": "emacs-overlay",
"rev": "b7c67b5f71db89ec27e1aa4413fbbcdf5bbfa451", "rev": "42f2c32d615b145ab47faeca4d9cfb48f7909052",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -291,11 +291,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1706830856, "lastModified": 1706569497,
"narHash": "sha256-a0NYyp+h9hlb7ddVz4LUn1vT/PLwqfrWYcHMvFB1xYg=", "narHash": "sha256-oixb0IDb5eZYw6BaVr/R/1pSoMh4rfJHkVnlgeRIeZs=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "b253292d9c0a5ead9bc98c4e9a26c6312e27d69f", "rev": "60c614008eed1d0383d21daac177a3e036192ed8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -414,11 +414,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1707114923, "lastModified": 1706746258,
"narHash": "sha256-LDYPWa+BgxHSNEye93SyIPgz5u3RAfh78P9KyO+rQzI=", "narHash": "sha256-9iNK1cP/dxCFh1NYVLJHijoJxlT3bXxTQToMDNZtjzU=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "afcedcf2c8e424d0465e823cf833eb3adebe1db7", "rev": "2db6a2a42930ffff0ffd690dec3f2c0b6f4fe66d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -438,11 +438,11 @@
"spectrum": "spectrum" "spectrum": "spectrum"
}, },
"locked": { "locked": {
"lastModified": 1707084830, "lastModified": 1706214321,
"narHash": "sha256-550b8OUt8j5G3tC4MgCfc+sHAAxARXzWYcYpfhNDhUc=", "narHash": "sha256-42FZWeJQNYgz0ZkclMzShuvjT9TvJNRN78Iu3SEyD4M=",
"owner": "astro", "owner": "astro",
"repo": "microvm.nix", "repo": "microvm.nix",
"rev": "c5074bb6d328a6071a70dcb097f8bcd208fce80a", "rev": "186b8bf6dbacc1ab55fe8ac8d5a2bbf76a1a70e1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -521,11 +521,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1706834982, "lastModified": 1706782449,
"narHash": "sha256-3CfxA7gZ+DVv/N9Pvw61bV5Oe/mWfxYPyVQGqp9TMJA=", "narHash": "sha256-8hEkOJDqR+7gJvXzwIM/VhR9iQzZyrNeh68u+Et2TzA=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "83e571bb291161682b9c3ccd48318f115143a550", "rev": "cc65e27670abccced5997d4a93c4c930aef6fd0b",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -553,11 +553,11 @@
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"dir": "lib", "dir": "lib",
"lastModified": 1706550542, "lastModified": 1703961334,
"narHash": "sha256-UcsnCG6wx++23yeER4Hg18CXWbgNpqNXcHIo5/1Y+hc=", "narHash": "sha256-M1mV/Cq+pgjk0rt6VxoyyD+O8cOUiai8t9Q6Yyq4noY=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "97b17f32362e475016f942bbdfda4a4a72a8a652", "rev": "b0d36bd0a420ecee3bc916c91886caca87c894e9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -586,11 +586,11 @@
}, },
"nixpkgs-stable_2": { "nixpkgs-stable_2": {
"locked": { "locked": {
"lastModified": 1706826059, "lastModified": 1706515015,
"narHash": "sha256-N69Oab+cbt3flLvYv8fYnEHlBsWwdKciNZHUbynVEOA=", "narHash": "sha256-eFfY5A7wlYy3jD/75lx6IJRueg4noE+jowl0a8lIlVo=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "25e3d4c0d3591c99929b1ec07883177f6ea70c9d", "rev": "f4a8d6d5324c327dcc2d863eb7f3cc06ad630df4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -634,11 +634,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1706913249, "lastModified": 1706550542,
"narHash": "sha256-x3M7iV++CsvRXI1fpyFPduGELUckZEhSv0XWnUopAG8=", "narHash": "sha256-UcsnCG6wx++23yeER4Hg18CXWbgNpqNXcHIo5/1Y+hc=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "e92b6015881907e698782c77641aa49298330223", "rev": "97b17f32362e475016f942bbdfda4a4a72a8a652",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -762,11 +762,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1707099356, "lastModified": 1706753617,
"narHash": "sha256-ph483MDKLi9I/gndYOieVP41es633DOOmPjEI50x5KU=", "narHash": "sha256-ZKqTFzhFwSWFEpQTJ0uXnfJBs5Y/po9/8TK4bzssdbs=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "61dfa5a8129f7edbe9150253c68f673f87b16fb1", "rev": "58be43ae223034217ea1bd58c73210644031b687",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -783,11 +783,11 @@
"nixpkgs-stable": "nixpkgs-stable_4" "nixpkgs-stable": "nixpkgs-stable_4"
}, },
"locked": { "locked": {
"lastModified": 1707015547, "lastModified": 1706410821,
"narHash": "sha256-YZr0OrqWPdbwBhxpBu69D32ngJZw8AMgZtJeaJn0e94=", "narHash": "sha256-iCfXspqUOPLwRobqQNAQeKzprEyVowLMn17QaRPQc+M=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "23f61b897c00b66855074db471ba016e0cda20dd", "rev": "73bf36912e31a6b21af6e0f39218e067283c67ef",
"type": "github" "type": "github"
}, },
"original": { "original": {

193
flake.nix
View file

@ -133,53 +133,51 @@
}; };
outputs = outputs =
{ { self
self, , sops
sops, , flake-parts
flake-parts, , ...
... } @ inputs:
}@inputs: with inputs; let
with inputs; machines = import ./machines inputs;
let in
machines = import ./machines inputs; flake-parts.lib.mkFlake { inherit inputs; } {
in
flake-parts.lib.mkFlake { inherit inputs; } {
systems = [ systems = [
"x86_64-linux" "x86_64-linux"
"aarch64-linux" "aarch64-linux"
]; ];
imports = [ inputs.pre-commit-hooks.flakeModule ]; imports = [
inputs.pre-commit-hooks.flakeModule
];
flake = { flake = {
lib = import ./lib inputs; lib = import ./lib inputs;
overlays.default = import ./overlays; overlays.default = import ./overlays;
nixosModules = builtins.listToAttrs ( nixosModules = builtins.listToAttrs (map
map
(x: { (x: {
name = x; name = x;
value = import (./modules + "/${x}"); value = import (./modules + "/${x}");
}) })
(builtins.attrNames (builtins.readDir ./modules)) (builtins.attrNames (builtins.readDir ./modules)));
);
nixosConfigurations = builtins.listToAttrs ( nixosConfigurations = builtins.listToAttrs (map
map
(machine: { (machine: {
name = machine; name = machine;
value = value = self.lib.defSystem (machines.${machine}.system or "x86_64-linux")
self.lib.defSystem (machines.${machine}.system or "x86_64-linux") {
{ imports = [ machines.${machine}.config ]; } imports = [
(machines.${machine}.deploy or null); machines.${machine}.config
];
}
(machines.${machine}.deploy or null);
}) })
(builtins.attrNames machines) (builtins.attrNames machines));
);
colmena = colmena = {
{
meta = { meta = {
nixpkgs = import nixpkgs { system = "x86_64-linux"; }; nixpkgs = import nixpkgs { system = "x86_64-linux"; };
@ -187,41 +185,29 @@
inherit nixpkgs; inherit nixpkgs;
}; };
}; };
} } // builtins.listToAttrs (map
// builtins.listToAttrs ( (machine: {
map name = machine;
(machine: { value = {
name = machine; deployment = {
value = { targetHost = machines.${machine}.deploy.host;
deployment = { targetUser = "root"; # machines.${machine}.deploy.sshUser;
targetHost = machines.${machine}.deploy.host; # targetUser = machines.${machine}.deploy.sshUser;
targetUser = "root"; # machines.${machine}.deploy.sshUser; tags = machines.${machine}.deploy.tags or [ ];
# targetUser = machines.${machine}.deploy.sshUser;
tags = machines.${machine}.deploy.tags or [ ];
};
imports =
self.lib.systemModules (machines.${machine}.system or "x86_64-linux")
machines.${machine}.config;
}; };
}) imports = self.lib.systemModules (machines.${machine}.system or "x86_64-linux") machines.${machine}.config;
(builtins.filter (machine: machines.${machine} ? deploy) (builtins.attrNames machines)) };
); })
}; (builtins.filter (machine: machines.${machine} ? deploy) (builtins.attrNames machines)));
perSystem = };
{
inputs', perSystem = { inputs', pkgs, config, ... }: {
pkgs,
config,
lib,
...
}:
{
pre-commit = { pre-commit = {
settings = { settings = {
hooks = { hooks = {
nixfmt.enable = true; nixpkgs-fmt.enable = true;
deadnix.enable = true; deadnix.enable = true;
black.enable = true; black.enable = true;
shellcheck = { shellcheck = {
@ -230,9 +216,6 @@
}; };
shfmt.enable = true; shfmt.enable = true;
}; };
tools = {
nixfmt = lib.mkForce pkgs.nixfmt-rfc-style;
};
}; };
}; };
@ -241,49 +224,49 @@
openfga = pkgs.callPackage ./pkgs/openfga { }; openfga = pkgs.callPackage ./pkgs/openfga { };
}; };
devShells.default = devShells.default = with pkgs; mkShell {
with pkgs; name = "dotfiles";
mkShell { packages = [
name = "dotfiles"; pkgs.sops
packages = [ ssh-to-age
age age
colmena nodejs
just nodePackages.typescript-language-server
nodejs nodePackages.yaml-language-server
nodePackages.typescript-language-server nodePackages.vscode-css-languageserver-bin
nodePackages.yaml-language-server nodePackages.prettier
nodePackages.vscode-css-languageserver-bin multimarkdown
nodePackages.prettier nix-diff
multimarkdown nix-prefetch
nix-diff nix-prefetch-scripts
nixfmt-rfc-style nix-prefetch-github
nix-prefetch nix-prefetch-docker
nix-prefetch-docker nix-top
nix-prefetch-github nix-tree
nix-prefetch-scripts taplo
nix-tree just
nix-top pciutils
pciutils
pkgs.sops
ssh-to-age
taplo
inputs'.disko.packages.disko cryptsetup
];
shellHook = '' inputs'.disko.packages.disko
${config.pre-commit.installationScript}
'';
};
devShells.install = colmena
with pkgs; ];
mkShell {
name = "install";
packages = [ inputs'.disko.packages.disko ];
};
formatter = pkgs.nixfmt-rfc-style; shellHook = ''
${config.pre-commit.installationScript}
'';
};
devShells.install = with pkgs; mkShell {
name = "install";
packages = [
inputs'.disko.packages.disko
];
};
formatter = pkgs.nixpkgs-fmt;
}; };
}; };
} }

View file

@ -1,27 +1,19 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.alacritty; cfg = config.eboskma.programs.alacritty;
importYAML = importYAML = name: yamlFile: (lib.importJSON ((pkgs.runCommandNoCC name { } ''
name: yamlFile: mkdir -p $out
(lib.importJSON ( ${pkgs.yaml2json}/bin/yaml2json < ${yamlFile} | ${pkgs.jq}/bin/jq -a '.' > $out/tmp.json
(pkgs.runCommandNoCC name { } '' '').outPath
mkdir -p $out + "/tmp.json"));
${pkgs.yaml2json}/bin/yaml2json < ${yamlFile} | ${pkgs.jq}/bin/jq -a '.' > $out/tmp.json theme = importYAML "theme" (builtins.fetchurl {
'').outPath url = "https://raw.githubusercontent.com/dracula/alacritty/77aff04b9f2651eac10e5cfa80a3d85ce43e7985/dracula.yml";
+ "/tmp.json" sha256 = "NoEBy8cUs6KDfougzAIcuX9oSAltO7y9OOeXJbSQKrY=";
)); });
theme = importYAML "theme" (
builtins.fetchurl {
url = "https://raw.githubusercontent.com/dracula/alacritty/77aff04b9f2651eac10e5cfa80a3d85ce43e7985/dracula.yml";
sha256 = "NoEBy8cUs6KDfougzAIcuX9oSAltO7y9OOeXJbSQKrY=";
}
);
in in
{ {
options.eboskma.programs.alacritty.enable = mkEnableOption "Enable alacritty"; options.eboskma.programs.alacritty.enable = mkEnableOption "Enable alacritty";

View file

@ -1,19 +1,11 @@
{ { pkgs, config, lib, flake-inputs, ... }:
pkgs,
config,
lib,
flake-inputs,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.anyrun; cfg = config.eboskma.programs.anyrun;
anyrunPkgs = flake-inputs.anyrun.packages."${pkgs.system}"; anyrunPkgs = flake-inputs.anyrun.packages."${pkgs.system}";
in in
{ {
options.eboskma.programs.anyrun = { options.eboskma.programs.anyrun = { enable = mkEnableOption "anyrun"; };
enable = mkEnableOption "anyrun";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.anyrun = { programs.anyrun = {
@ -28,15 +20,9 @@ in
symbols symbols
translate translate
]; ];
width = { width = { fraction = 0.3; };
fraction = 0.3; x = { fraction = 0.5; };
}; y = { absolute = 60; };
x = {
fraction = 0.5;
};
y = {
absolute = 60;
};
layer = "overlay"; layer = "overlay";
}; };

View file

@ -4,14 +4,13 @@ let
cfg = config.eboskma.programs.atuin; cfg = config.eboskma.programs.atuin;
in in
{ {
options.eboskma.programs.atuin = { options.eboskma.programs.atuin = { enable = mkEnableOption "atuin"; };
enable = mkEnableOption "atuin";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.atuin = { programs.atuin = {
enable = true; enable = true;
flags = [ ]; flags = [
];
settings = { settings = {
dialect = "uk"; dialect = "uk";

View file

@ -1,6 +1,8 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.programs.bat; cfg = config.eboskma.programs.bat;
in in
{ {
@ -14,7 +16,9 @@ in
config = { config = {
theme = "Monokai Extended Bright"; theme = "Monokai Extended Bright";
pager = "less -FR"; pager = "less -FR";
map-syntax = [ "*.heex:HTML (EEx)" ]; map-syntax = [
"*.heex:HTML (EEx)"
];
}; };
}; };
}; };

View file

@ -1,16 +1,13 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.cargo; cfg = config.eboskma.programs.cargo;
tomlFormat = pkgs.formats.toml { }; tomlFormat = pkgs.formats.toml { };
cargoConfig = types.submodule { freeformType = tomlFormat.type; }; cargoConfig = types.submodule {
freeformType = tomlFormat.type;
};
in in
{ {
options.eboskma.programs.cargo = { options.eboskma.programs.cargo = {

View file

@ -1,17 +1,13 @@
{ { pkgs
pkgs, , lib
lib, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.dropbox; cfg = config.eboskma.programs.dropbox;
in in
{ {
options.eboskma.programs.dropbox = { options.eboskma.programs.dropbox = { enable = mkEnableOption "dropbox using the maestral client"; };
enable = mkEnableOption "dropbox using the maestral client";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
systemd.user.services = { systemd.user.services = {
@ -35,9 +31,6 @@ in
}; };
}; };
home.packages = [ home.packages = [ pkgs.maestral-gui pkgs.maestral ];
pkgs.maestral-gui
pkgs.maestral
];
}; };
} }

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.dunst; cfg = config.eboskma.programs.dunst;
in in
{ {

View file

@ -1,6 +1,8 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.programs.electron; cfg = config.eboskma.programs.electron;
in in
{ {

View file

@ -1,20 +1,16 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.emacs; cfg = config.eboskma.programs.emacs;
tangleEmacsConfig = tangleEmacsConfig = initFile: pkgs.runCommand "tangled-emacs-${initFile}" { } ''
initFile: cp ${./config.org} ./config.org
pkgs.runCommand "tangled-emacs-${initFile}" { } '' ${cfg.package}/bin/emacs --batch --quick --load org ./config.org --funcall org-babel-tangle
cp ${./config.org} ./config.org cp ${initFile} $out
${cfg.package}/bin/emacs --batch --quick --load org ./config.org --funcall org-babel-tangle '';
cp ${initFile} $out
'';
tree-sitter-hare = pkgs.tree-sitter.buildGrammar { tree-sitter-hare = pkgs.tree-sitter.buildGrammar {
language = "tree-sitter-hare"; language = "tree-sitter-hare";
@ -49,86 +45,80 @@ let
package = cfg.package; package = cfg.package;
alwaysEnsure = true; alwaysEnsure = true;
alwaysTangle = true; alwaysTangle = true;
extraEmacsPackages = extraEmacsPackages = epkgs: with epkgs; [
epkgs: with epkgs; [ hare-mode
hare-mode vterm
vterm (treesit-grammars.with-grammars (p: with p; [
(treesit-grammars.with-grammars ( tree-sitter-bash
p: with p; [ tree-sitter-c
tree-sitter-bash tree-sitter-c-sharp
tree-sitter-c tree-sitter-css
tree-sitter-c-sharp tree-sitter-cmake
tree-sitter-css tree-sitter-comment
tree-sitter-cmake tree-sitter-commonlisp
tree-sitter-comment tree-sitter-cpp
tree-sitter-commonlisp tree-sitter-css
tree-sitter-cpp tree-sitter-cuda
tree-sitter-css tree-sitter-devicetree
tree-sitter-cuda tree-sitter-dockerfile
tree-sitter-devicetree tree-sitter-dot
tree-sitter-dockerfile tree-sitter-eex
tree-sitter-dot tree-sitter-elisp
tree-sitter-eex tree-sitter-elixir
tree-sitter-elisp tree-sitter-embedded-template
tree-sitter-elixir tree-sitter-erlang
tree-sitter-embedded-template tree-sitter-fish
tree-sitter-erlang tree-sitter-glsl
tree-sitter-fish tree-sitter-go
tree-sitter-glsl tree-sitter-gomod
tree-sitter-go tree-sitter-gowork
tree-sitter-gomod tree-sitter-graphql
tree-sitter-gowork tree-sitter-hare
tree-sitter-graphql tree-sitter-haskell
tree-sitter-hare tree-sitter-hcl
tree-sitter-haskell tree-sitter-heex
tree-sitter-hcl tree-sitter-html
tree-sitter-heex tree-sitter-http
tree-sitter-html tree-sitter-javascript
tree-sitter-http tree-sitter-jsdoc
tree-sitter-javascript tree-sitter-json
tree-sitter-jsdoc tree-sitter-latex
tree-sitter-json tree-sitter-llvm
tree-sitter-latex tree-sitter-lua
tree-sitter-llvm tree-sitter-make
tree-sitter-lua tree-sitter-markdown
tree-sitter-make tree-sitter-markdown-inline
tree-sitter-markdown tree-sitter-nix
tree-sitter-markdown-inline tree-sitter-nu
tree-sitter-nix tree-sitter-pioasm
tree-sitter-nu tree-sitter-python
tree-sitter-pioasm tree-sitter-query
tree-sitter-python tree-sitter-regex
tree-sitter-query tree-sitter-rst
tree-sitter-regex tree-sitter-ruby
tree-sitter-rst tree-sitter-rust
tree-sitter-ruby tree-sitter-scheme
tree-sitter-rust tree-sitter-scss
tree-sitter-scheme tree-sitter-sql
tree-sitter-scss tree-sitter-surface
tree-sitter-sql tree-sitter-svelte
tree-sitter-surface tree-sitter-toml
tree-sitter-svelte tree-sitter-tsx
tree-sitter-toml tree-sitter-typescript
tree-sitter-tsx tree-sitter-verilog
tree-sitter-typescript tree-sitter-yaml
tree-sitter-verilog tree-sitter-zig
tree-sitter-yaml ]))
tree-sitter-zig emacsql
] emacsql-sqlite
)) ];
emacsql
emacsql-sqlite
];
}; };
orgProtocolDesktop = pkgs.makeDesktopItem { orgProtocolDesktop = pkgs.makeDesktopItem {
name = "org-protocol"; name = "org-protocol";
desktopName = "Emacs Org Protocol Handler"; desktopName = "Emacs Org Protocol Handler";
icon = "emacs"; icon = "emacs";
categories = [ categories = [ "Development" "TextEditor" ];
"Development"
"TextEditor"
];
keywords = [ "org-protocol" ]; keywords = [ "org-protocol" ];
type = "Application"; type = "Application";
exec = "${emacsWithPackages}/bin/emacsclient -- %u"; exec = "${emacsWithPackages}/bin/emacsclient -- %u";
@ -167,31 +157,19 @@ in
home.file."emacs.d/early-init.el".source = tangleEmacsConfig "early-init.el"; home.file."emacs.d/early-init.el".source = tangleEmacsConfig "early-init.el";
home.packages = home.packages = with pkgs; [
with pkgs; (texlive.combine {
[ inherit (texlive) scheme-small wrapfig ulem capt-of;
(texlive.combine { })
inherit (texlive) orgProtocolDesktop
scheme-small nodePackages.bash-language-server
wrapfig aspell
ulem lldb
capt-of (nil.overrideAttrs (_: { doCheck = false; }))
; nixpkgs-fmt
}) python3
orgProtocolDesktop ] ++
nodePackages.bash-language-server (with aspellDicts; [ en en-computers en-science fy nl ]);
aspell
lldb
(nil.overrideAttrs (_: { doCheck = false; }))
nixpkgs-fmt
python3
]
++ (with aspellDicts; [
en
en-computers
en-science
fy
nl
]);
}; };
} }

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.eww; cfg = config.eboskma.programs.eww;

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.firefox; cfg = config.eboskma.programs.firefox;
profileSettings = { profileSettings = {
@ -26,16 +24,31 @@ let
}; };
nonDefaultDesktop = pkgs.makeDesktopItem { nonDefaultDesktop = pkgs.makeDesktopItem {
name = "firefox-" + (if cfg.work then "private" else "horus"); name =
desktopName = "Firefox (" + (if cfg.work then "Personal" else "Horus") + ")"; "firefox-"
exec = "firefox -P " + (if cfg.work then "private" else "horus") + " %u"; + (
if cfg.work
then "private"
else "horus"
);
desktopName =
"Firefox ("
+ (
if cfg.work
then "Personal"
else "Horus"
)
+ ")";
exec =
"firefox -P "
+ (
if cfg.work
then "private"
else "horus"
)
+ " %u";
icon = "firefox"; icon = "firefox";
categories = [ categories = [ "GNOME" "GTK" "Network" "WebBrowser" ];
"GNOME"
"GTK"
"Network"
"WebBrowser"
];
mimeTypes = [ mimeTypes = [
"text/html" "text/html"
"text/xml" "text/xml"

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.fish; cfg = config.eboskma.programs.fish;
in in
{ {
@ -39,7 +37,8 @@ in
vim = mkIf config.eboskma.programs.neovim.enable "nvim"; vim = mkIf config.eboskma.programs.neovim.enable "nvim";
vi = mkIf config.eboskma.programs.neovim.enable "nvim"; vi = mkIf config.eboskma.programs.neovim.enable "nvim";
}; };
interactiveShellInit = ""; interactiveShellInit = ''
'';
}; };
fzf = { fzf = {

View file

@ -1,5 +1,4 @@
{ git, coreutils }: { git, coreutils }: {
{
mark_prompt_start = { mark_prompt_start = {
onEvent = "fish_prompt"; onEvent = "fish_prompt";
body = '' body = ''

View file

@ -1,11 +1,5 @@
{ { pkgs, lib, config, ... }:
pkgs, with lib; let
lib,
config,
...
}:
with lib;
let
cfg = config.eboskma.programs.foot; cfg = config.eboskma.programs.foot;
in in
{ {

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.git; cfg = config.eboskma.programs.git;
in in
{ {
@ -36,11 +34,7 @@ in
signingKeyFormat = mkOption { signingKeyFormat = mkOption {
description = "the type of signing key"; description = "the type of signing key";
type = types.enum [ type = types.enum [ "openpgp" "x509" "ssh" ];
"openpgp"
"x509"
"ssh"
];
default = "openpgp"; default = "openpgp";
}; };
}; };

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.gpg; cfg = config.eboskma.programs.gpg;
in in
{ {
@ -14,7 +12,9 @@ in
}; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ pinentry-gnome ]; home.packages = with pkgs; [
pinentry-gnome
];
programs.gpg = { programs.gpg = {
enable = true; enable = true;

View file

@ -2,17 +2,18 @@
with lib; with lib;
let let
cfg = config.eboskma.programs.hyprland; cfg = config.eboskma.programs.hyprland;
# terminal = "${pkgs.foot}/bin/footclient";
# dmenu = "${pkgs.rofi}/bin/rofi -show drun -no-lazy-grab";
# menu = "${pkgs.rofi}/bin/rofi -show run -no-lazy-grab";
# rofiPower = pkgs.writeShellScriptBin "rofi-power" (builtins.readFile ../sway/powermenu.sh);
# powerMenu = "${rofiPower}/bin/rofi-power";
# swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ${../../../wallpapers/river-2560.png} --scaling fill";
in in
# terminal = "${pkgs.foot}/bin/footclient";
# dmenu = "${pkgs.rofi}/bin/rofi -show drun -no-lazy-grab";
# menu = "${pkgs.rofi}/bin/rofi -show run -no-lazy-grab";
# rofiPower = pkgs.writeShellScriptBin "rofi-power" (builtins.readFile ../sway/powermenu.sh);
# powerMenu = "${rofiPower}/bin/rofi-power";
# swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ${../../../wallpapers/river-2560.png} --scaling fill";
{ {
options.eboskma.programs.hyprland = { options.eboskma.programs.hyprland = { enable = mkEnableOption "Hyprland"; };
enable = mkEnableOption "Hyprland";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
# wayland.windowManager.hyprland = { # wayland.windowManager.hyprland = {

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.i3; cfg = config.eboskma.programs.i3;
mod = "Mod4"; mod = "Mod4";
i3lockcmd = "${pkgs.i3lock-color}/bin/i3lock-color --image ${toString ../../../wallpapers/river-3840.png} --color=333333ff --tiling --ignore-empty-password --show-failed-attempts --screen=0 --clock --pass-volume-keys"; i3lockcmd = "${pkgs.i3lock-color}/bin/i3lock-color --image ${toString ../../../wallpapers/river-3840.png} --color=333333ff --tiling --ignore-empty-password --show-failed-attempts --screen=0 --clock --pass-volume-keys";
@ -15,7 +13,8 @@ let
up = "i"; up = "i";
right = "o"; right = "o";
workspacePartition = builtins.partition (n: (trivial.mod n 2) != 0) (lists.range 1 10); workspacePartition =
builtins.partition (n: (trivial.mod n 2) != 0) (lists.range 1 10);
menu = "${pkgs.rofi}/bin/rofi -show drun -no-lazy-grab"; menu = "${pkgs.rofi}/bin/rofi -show drun -no-lazy-grab";
in in
@ -41,19 +40,10 @@ in
modifier = mod; modifier = mod;
assigns = { assigns = {
"1" = [ { class = "Firefox"; } ]; "1" = [{ class = "Firefox"; }];
"2" = [ "2" = [{ class = "Alacritty"; } { class = "foot"; }];
{ class = "Alacritty"; } "3" = [{ class = "Code"; } { class = "Emacs"; }];
{ class = "foot"; } "4" = [{ class = "telegramdesktop"; } { class = "Signal"; }];
];
"3" = [
{ class = "Code"; }
{ class = "Emacs"; }
];
"4" = [
{ class = "telegramdesktop"; }
{ class = "Signal"; }
];
}; };
# Dracula theme # Dracula theme
colors = { colors = {
@ -96,10 +86,7 @@ in
}; };
floating = { floating = {
criteria = [ criteria = [{ instance = "gnome-calculator"; } { class = "Pavucontrol"; }];
{ instance = "gnome-calculator"; }
{ class = "Pavucontrol"; }
];
modifier = mod; modifier = mod;
}; };
@ -215,24 +202,23 @@ in
bars = [ ]; bars = [ ];
workspaceAutoBackAndForth = true; workspaceAutoBackAndForth = true;
workspaceOutputAssign = builtins.concatLists ( workspaceOutputAssign = builtins.concatLists (builtins.attrValues (builtins.mapAttrs
builtins.attrValues ( (
builtins.mapAttrs name: workspaces:
( let
name: workspaces: output =
let if name == "right"
output = if name == "right" then "DP-0" else "DP-4"; then "DP-0"
in else "DP-4";
builtins.map in
(ws: { builtins.map
inherit output; (ws: {
workspace = toString ws; inherit output;
}) workspace = toString ws;
workspaces })
) workspaces
workspacePartition
) )
); workspacePartition));
# [ # [
# { output = "DP-0"; workspace = "1"; } # { output = "DP-0"; workspace = "1"; }
# ]; # ];
@ -248,12 +234,15 @@ in
} }
] ++ cfg.startupCommands; ] ++ cfg.startupCommands;
}; };
extraConfig = ""; extraConfig = ''
'';
}; };
}; };
home = { home = {
packages = with pkgs; [ dunst ]; packages = with pkgs; [
dunst
];
}; };
}; };
} }

View file

@ -1,17 +1,13 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.mpd; cfg = config.eboskma.programs.mpd;
in in
{ {
options.eboskma.programs.mpd = { options.eboskma.programs.mpd = { enable = mkEnableOption "mpd"; };
enable = mkEnableOption "mpd";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
services.mpd = { services.mpd = {
@ -32,9 +28,6 @@ in
notifications = true; notifications = true;
}; };
home.packages = with pkgs; [ home.packages = with pkgs; [ mpc-cli (ncmpcpp.override { visualizerSupport = true; }) ];
mpc-cli
(ncmpcpp.override { visualizerSupport = true; })
];
}; };
} }

View file

@ -1,17 +1,13 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.neovim; cfg = config.eboskma.programs.neovim;
in in
{ {
options.eboskma.programs.neovim = { options.eboskma.programs.neovim = { enable = mkEnableOption "neovim"; };
enable = mkEnableOption "neovim";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
# unfortunately this does properly support a Lua based config # unfortunately this does properly support a Lua based config
@ -32,10 +28,7 @@ in
# ''; # '';
# }; # };
home.packages = with pkgs; [ home.packages = with pkgs; [ neovim tree-sitter ];
neovim
tree-sitter
];
xdg.configFile.nvim = { xdg.configFile.nvim = {
source = ./config; source = ./config;

View file

@ -1,49 +1,37 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.nnn; cfg = config.eboskma.programs.nnn;
in in
{ {
options.eboskma.programs.nnn = { options.eboskma.programs.nnn = { enable = mkEnableOption "nnn"; };
enable = mkEnableOption "nnn";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.nnn = { programs.nnn = {
enable = true; enable = true;
package = package = (pkgs.nnn.overrideAttrs
(pkgs.nnn.overrideAttrs ( (_prevAttrs: {
_prevAttrs: { version = "unstable-2023-10-08";
version = "unstable-2023-10-08"; src = pkgs.fetchFromGitHub
src = pkgs.fetchFromGitHub { {
owner = "jarun"; owner = "jarun";
repo = "nnn"; repo = "nnn";
rev = "7f63bef4d6c9f70b99a4c98435c9c0a68e05be44"; rev = "7f63bef4d6c9f70b99a4c98435c9c0a68e05be44";
sha256 = "B9WRQW4wbs3+lJ9ACFheTaO+0+G/r67yJZJJPMDIQXI="; sha256 = "B9WRQW4wbs3+lJ9ACFheTaO+0+G/r67yJZJJPMDIQXI=";
}; };
} })
)).override ).override
{ {
withNerdIcons = true; withNerdIcons = true;
extraMakeFlags = [ extraMakeFlags = [ "O_COLEMAK=1" "O_GITSTATUS=1" ];
"O_COLEMAK=1" };
"O_GITSTATUS=1"
];
};
plugins = { plugins = {
src = src = (pkgs.fetchFromGitHub {
(pkgs.fetchFromGitHub { owner = "jarun";
owner = "jarun"; repo = "nnn";
repo = "nnn"; rev = "7f63bef4d6c9f70b99a4c98435c9c0a68e05be44";
rev = "7f63bef4d6c9f70b99a4c98435c9c0a68e05be44"; sha256 = "B9WRQW4wbs3+lJ9ACFheTaO+0+G/r67yJZJJPMDIQXI=";
sha256 = "B9WRQW4wbs3+lJ9ACFheTaO+0+G/r67yJZJJPMDIQXI="; }) + "/plugins";
})
+ "/plugins";
mappings = { mappings = {
c = "fzcd"; c = "fzcd";

View file

@ -1,19 +1,13 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.nushell; cfg = config.eboskma.programs.nushell;
zoxideOptions = concatStringsSep " " config.programs.zoxide.options; zoxideOptions = concatStringsSep " " config.programs.zoxide.options;
in in
{ {
options.eboskma.programs.nushell = { options.eboskma.programs.nushell = { enable = mkEnableOption "nu shell"; };
enable = mkEnableOption "nu shell";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.nushell = { programs.nushell = {

View file

@ -1,20 +1,15 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.nyxt; cfg = config.eboskma.programs.nyxt;
in in
{ {
options.eboskma.programs.nyxt = { options.eboskma.programs.nyxt = { enable = mkEnableOption "nyxt web browser"; };
enable = mkEnableOption "nyxt web browser";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = [ pkgs.nyxt ]; home.packages = [
pkgs.nyxt
];
xdg.configFile.nyxt-config = { xdg.configFile.nyxt-config = {
target = "nyxt/config.lisp"; target = "nyxt/config.lisp";

View file

@ -1,30 +1,27 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.obs-studio; cfg = config.eboskma.programs.obs-studio;
in in
{ {
options.eboskma.programs.obs-studio = { options.eboskma.programs.obs-studio = { enable = mkEnableOption "activate obs-studio"; };
enable = mkEnableOption "activate obs-studio";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.obs-studio = { programs.obs-studio = {
enable = true; enable = true;
plugins = plugins = [
[ pkgs.obs-backgroundremoval ] pkgs.obs-backgroundremoval
++ (with pkgs.obs-studio-plugins; [ ]
wlrobs ++ (with pkgs.obs-studio-plugins; [
obs-vaapi wlrobs
obs-gstreamer obs-vaapi
obs-pipewire-audio-capture obs-gstreamer
obs-vkcapture obs-pipewire-audio-capture
]); obs-vkcapture
]);
}; };
}; };
} }

View file

@ -1,12 +1,12 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.programs.picom; cfg = config.eboskma.programs.picom;
in in
{ {
options.eboskma.programs.picom = { options.eboskma.programs.picom = { enable = mkEnableOption "activate picom"; };
enable = mkEnableOption "activate picom";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
# home.packages = [pkgs.nixgl.auto.nixGLDefault]; # home.packages = [pkgs.nixgl.auto.nixGLDefault];
@ -18,10 +18,7 @@ in
vSync = true; vSync = true;
fade = false; fade = false;
fadeSteps = [ fadeSteps = [ 0.08 0.08 ];
8.0e-2
8.0e-2
];
shadow = true; shadow = true;
@ -57,20 +54,10 @@ in
inactive-dim = 0.1; inactive-dim = 0.1;
wintypes = { wintypes = {
dock = { dock = { shadow = false; };
shadow = false; dnd = { shadow = false; };
}; popup_menu = { shadow = false; opacity = 1.0; };
dnd = { dropdown_menu = { shadow = false; opacity = 1.0; };
shadow = false;
};
popup_menu = {
shadow = false;
opacity = 1.0;
};
dropdown_menu = {
shadow = false;
opacity = 1.0;
};
}; };
}; };
}; };

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.polybar; cfg = config.eboskma.programs.polybar;
colors = { colors = {
@ -16,7 +14,9 @@ let
polybar-playerctl = polybar-playerctl =
let let
pythonWithPackages = pkgs.python3.withPackages (pythonPackages: [ pythonPackages.pygobject3 ]); pythonWithPackages = pkgs.python3.withPackages (pythonPackages: [
pythonPackages.pygobject3
]);
in in
pkgs.stdenv.mkDerivation { pkgs.stdenv.mkDerivation {
name = "polybar-playerctl"; name = "polybar-playerctl";
@ -68,9 +68,7 @@ let
''; '';
in in
{ {
options.eboskma.programs.polybar = { options.eboskma.programs.polybar = { enable = mkEnableOption "activate polybar"; };
enable = mkEnableOption "activate polybar";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
# systemd.user.services.polybar = { # systemd.user.services.polybar = {
@ -109,7 +107,7 @@ in
}; };
"bar/main" = { "bar/main" = {
monitor = "\${env:MONITOR:DP-0}"; monitor = ''''${env:MONITOR:DP-0}'';
fixed.center = true; fixed.center = true;
width = "100%"; width = "100%";
height = 48; height = 48;
@ -309,11 +307,7 @@ in
muted.text = " Muted"; muted.text = " Muted";
}; };
ramp.volume = [ ramp.volume = [ "󰕿" "󰖀" "󰕾" ]; # Icons: volume_low volume_medium volume_high
"󰕿"
"󰖀"
"󰕾"
]; # Icons: volume_low volume_medium volume_high
click.right = "${pkgs.pavucontrol}/bin/pavucontrol"; click.right = "${pkgs.pavucontrol}/bin/pavucontrol";
}; };

View file

@ -1,15 +1,9 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.rclone; cfg = config.eboskma.programs.rclone;
rcloneConnectionString = rcloneConnectionString = mount:
mount:
let let
type = mount.remoteConfig.type; type = mount.remoteConfig.type;
config = builtins.removeAttrs mount.remoteConfig [ "type" ]; config = builtins.removeAttrs mount.remoteConfig [ "type" ];
@ -17,34 +11,24 @@ let
in in
":${type},${builtins.concatStringsSep "," connectionStringOptions}:${mount.remote}"; ":${type},${builtins.concatStringsSep "," connectionStringOptions}:${mount.remote}";
rcloneRemote = rcloneRemote = with types; attrsOf (oneOf [ str int bool ]);
with types;
attrsOf (
oneOf [
str
int
bool
]
);
rcloneMount = rcloneMount = with types; submodule {
with types; options = {
submodule { remoteConfig = mkOption {
options = { description = "Configuration for the remote to use";
remoteConfig = mkOption { type = rcloneRemote;
description = "Configuration for the remote to use"; };
type = rcloneRemote; remote = mkOption {
}; description = "Remote path";
remote = mkOption { type = str;
description = "Remote path"; };
type = str; local = mkOption {
}; description = "Local mountpoint";
local = mkOption { type = path;
description = "Local mountpoint";
type = path;
};
}; };
}; };
};
in in
{ {
options.eboskma.programs.rclone = { options.eboskma.programs.rclone = {
@ -60,40 +44,36 @@ in
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = [ pkgs.rclone ]; home.packages = [ pkgs.rclone ];
systemd.user.services = builtins.listToAttrs ( systemd.user.services = builtins.listToAttrs (builtins.map
builtins.map (mount:
( let
mount: localPath = toString mount.local;
let unitName = builtins.replaceStrings [ "/" ] [ "-" ] (builtins.substring 1 (builtins.stringLength localPath) localPath);
localPath = toString mount.local; in
unitName = builtins.replaceStrings [ "/" ] [ "-" ] ( {
builtins.substring 1 (builtins.stringLength localPath) localPath name = "rclone-${unitName}";
); value = {
in Unit = {
{ Description = "rclone mount ${unitName}";
name = "rclone-${unitName}"; After = [ "network.target" ];
value = { AssertPathIsDirectory = toString mount.local;
Unit = {
Description = "rclone mount ${unitName}";
After = [ "network.target" ];
AssertPathIsDirectory = toString mount.local;
};
Service = {
Environment = [ "PATH=/run/wrappers/bin:$PATH" ];
ExecStart = "${pkgs.rclone}/bin/rclone mount --vfs-cache-mode full --vfs-cache-poll-interval 5s --poll-interval 5s --dir-cache-time 10s --umask 022 --allow-other ${rcloneConnectionString mount} ${mount.local}";
ExecStop = "/run/wrappers/bin/fusermount -zu ${mount.local}";
Restart = "on-failure";
RestartSec = 10;
};
Install = {
WantedBy = [ "default.target" ];
};
}; };
}
) Service = {
cfg.mounts Environment = [
); "PATH=/run/wrappers/bin:$PATH"
];
ExecStart = "${pkgs.rclone}/bin/rclone mount --vfs-cache-mode full --vfs-cache-poll-interval 5s --poll-interval 5s --dir-cache-time 10s --umask 022 --allow-other ${rcloneConnectionString mount} ${mount.local}";
ExecStop = "/run/wrappers/bin/fusermount -zu ${mount.local}";
Restart = "on-failure";
RestartSec = 10;
};
Install = {
WantedBy = [ "default.target" ];
};
};
})
cfg.mounts);
}; };
} }

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.rofi; cfg = config.eboskma.programs.rofi;
in in
{ {

View file

@ -1,17 +1,17 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.solvespace; cfg = config.eboskma.programs.solvespace;
in in
{ {
options.eboskma.programs.solvespace = { options.eboskma.programs.solvespace = { enable = mkEnableOption "activate solvespace"; };
enable = mkEnableOption "activate solvespace";
};
config = mkIf cfg.enable { home.packages = with pkgs; [ solvespace ]; }; config = mkIf cfg.enable {
home.packages = with pkgs; [
solvespace
];
};
} }

View file

@ -1,15 +1,15 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.programs.ssh; cfg = config.eboskma.programs.ssh;
var = config.eboskma.var; var = config.eboskma.var;
personalKey = "~/.ssh/id_ed25519_sk_personal.pub"; personalKey = "~/.ssh/id_ed25519_sk_personal.pub";
horusKey = "~/.ssh/id_ed25519_sk_horus.pub"; horusKey = "~/.ssh/id_ed25519_sk_horus.pub";
in in
{ {
options.eboskma.programs.ssh = { options.eboskma.programs.ssh = { enable = mkEnableOption "activate ssh"; };
enable = mkEnableOption "activate ssh";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.ssh = { programs.ssh = {
@ -60,15 +60,12 @@ in
identityFile = personalKey; identityFile = personalKey;
}; };
hass = { hass =
hostname = "10.0.0.254"; {
user = "root"; hostname = "10.0.0.254";
identityFile = "~/.ssh/id_ed25519"; user = "root";
extraOptions = { identityFile = "~/.ssh/id_ed25519";
ControlMaster = "auto";
ControlPersist = "10m";
}; };
};
horus-vpn = { horus-vpn = {
hostname = "192.168.4.202"; hostname = "192.168.4.202";

View file

@ -4,9 +4,7 @@ let
cfg = config.eboskma.programs.starship; cfg = config.eboskma.programs.starship;
in in
{ {
options.eboskma.programs.starship = { options.eboskma.programs.starship = { enable = mkEnableOption "starship"; };
enable = mkEnableOption "starship";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.starship = { programs.starship = {

View file

@ -1,19 +1,14 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.sway; cfg = config.eboskma.programs.sway;
mod = "Mod4"; mod = "Mod4";
swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ${cfg.lock-wallpaper} --scaling fill"; swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ${cfg.lock-wallpaper} --scaling fill";
rofiPower = pkgs.writeShellScriptBin "rofi-power" ( rofiPower = pkgs.writeShellScriptBin "rofi-power"
builtins.replaceStrings [ "{WALLPAPER}" ] [ (builtins.toString cfg.lock-wallpaper) ] ( (builtins.replaceStrings [ "{WALLPAPER}" ] [ (builtins.toString cfg.lock-wallpaper) ] (builtins.readFile ./powermenu.sh));
builtins.readFile ./powermenu.sh
)
);
in in
{ {
options.eboskma.programs.sway = { options.eboskma.programs.sway = {
@ -36,42 +31,38 @@ in
}; };
startup = mkOption { startup = mkOption {
description = "Commands that should be executed at startup."; description = "Commands that should be executed at startup.";
type = types.listOf ( type = types.listOf (types.submodule {
types.submodule { options = {
options = { command = mkOption {
command = mkOption { type = types.str;
type = types.str; description = "Command that will be executed on startup.";
description = "Command that will be executed on startup.";
};
always = mkOption {
type = types.bool;
default = false;
description = "Whether to run command on each ${moduleName} restart.";
};
}; };
}
); always = mkOption {
type = types.bool;
default = false;
description = "Whether to run command on each ${moduleName} restart.";
};
};
});
}; };
workspaceOutputs = mkOption { workspaceOutputs = mkOption {
description = "Assign workspaces to outputs"; description = "Assign workspaces to outputs";
type = types.listOf ( type = types.listOf (types.submodule {
types.submodule { options = {
options = { output = mkOption {
output = mkOption { description = "Name(s) of the output to assign";
description = "Name(s) of the output to assign"; type = with types; either str (listOf str);
type = with types; either str (listOf str); apply = lists.toList;
apply = lists.toList; default = "";
default = "";
};
workspace = mkOption {
description = "Name of the workspace to assign";
type = types.str;
default = "";
};
}; };
} workspace = mkOption {
); description = "Name of the workspace to assign";
type = types.str;
default = "";
};
};
});
default = [ ]; default = [ ];
}; };
@ -89,12 +80,9 @@ in
modifier = mod; modifier = mod;
assigns = { assigns = {
"1" = [ { app_id = "firefox"; } ]; "1" = [{ app_id = "firefox"; }];
"2" = [ { app_id = "foot"; } ]; "2" = [{ app_id = "foot"; }];
"3" = [ "3" = [{ class = "Code"; } { app_id = "emacs"; }];
{ class = "Code"; }
{ app_id = "emacs"; }
];
}; };
bars = [ ]; bars = [ ];
@ -148,7 +136,7 @@ in
right = "o"; right = "o";
floating = { floating = {
criteria = [ { app_id = "gnome-calculator"; } ]; criteria = [{ app_id = "gnome-calculator"; }];
modifier = mod; modifier = mod;
}; };
@ -245,9 +233,9 @@ in
"${mod}+c" = mkIf config.eboskma.programs.emacs.enable "exec ${config.programs.emacs.package}/bin/emacsclient -c"; "${mod}+c" = mkIf config.eboskma.programs.emacs.enable "exec ${config.programs.emacs.package}/bin/emacsclient -c";
"${mod}+Print" = "exec ${pkgs.grim}/bin/grim -o $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${pkgs.jaq}/bin/jaq -r '.[] | select(.focused) | .name')"; "${mod}+Print" = "exec ${pkgs.grim}/bin/grim -o $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${pkgs.jaq}/bin/jaq -r '.[] | select(.focused) | .name')";
"${mod}+Shift+Print" = ''exec ${pkgs.grim}/bin/grim -o $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${pkgs.jaq}/bin/jaq -r '.[] | select(.focused) | .name') - | ${pkgs.wl-clipboard}/bin/wl-copy -t "image/png" -f''; "${mod}+Shift+Print" = "exec ${pkgs.grim}/bin/grim -o $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${pkgs.jaq}/bin/jaq -r '.[] | select(.focused) | .name') - | ${pkgs.wl-clipboard}/bin/wl-copy -t \"image/png\" -f";
"${mod}+Shift+Ctrl+Print" = ''exec ${pkgs.grim}/bin/grim -g "$(${pkgs.slurp}/bin/slurp)" - | ${pkgs.wl-clipboard}/bin/wl-copy -t "image/png" -f''; "${mod}+Shift+Ctrl+Print" = "exec ${pkgs.grim}/bin/grim -g \"$(${pkgs.slurp}/bin/slurp)\" - | ${pkgs.wl-clipboard}/bin/wl-copy -t \"image/png\" -f";
"${mod}+Shift+Alt+Print" = ''exec ${pkgs.grim}/bin/grim -g "$(${pkgs.slurp}/bin/slurp)"''; "${mod}+Shift+Alt+Print" = "exec ${pkgs.grim}/bin/grim -g \"$(${pkgs.slurp}/bin/slurp)\"";
"XF86AudioRaiseVolume" = "exec ${pkgs.pamedia}/bin/pamedia up"; "XF86AudioRaiseVolume" = "exec ${pkgs.pamedia}/bin/pamedia up";
"XF86AudioLowerVolume" = "exec ${pkgs.pamedia}/bin/pamedia down"; "XF86AudioLowerVolume" = "exec ${pkgs.pamedia}/bin/pamedia down";
@ -256,6 +244,7 @@ in
"${mod}+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-panel --skip-wait"; "${mod}+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-panel --skip-wait";
"${mod}+Shift+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-dnd --skip-wait"; "${mod}+Shift+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-dnd --skip-wait";
} // cfg.extraKeybindings; } // cfg.extraKeybindings;
modes = { modes = {

View file

@ -1,18 +1,11 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.swaynotificationcenter; cfg = config.eboskma.programs.swaynotificationcenter;
settingsFormat = pkgs.formats.json { }; settingsFormat = pkgs.formats.json { };
in in
{ {
options.eboskma.programs.swaynotificationcenter = { options.eboskma.programs.swaynotificationcenter = { enable = mkEnableOption "SwayNotificationCenter"; };
enable = mkEnableOption "SwayNotificationCenter";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ swaynotificationcenter ]; home.packages = with pkgs; [ swaynotificationcenter ];

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.programs.tea; cfg = config.eboskma.programs.tea;
@ -88,6 +83,7 @@ let
}; };
}; };
}; };
in in
{ {
options.eboskma.programs.tea = { options.eboskma.programs.tea = {

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.tmux; cfg = config.eboskma.programs.tmux;
in in
{ {

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.vscode; cfg = config.eboskma.programs.vscode;
in in
{ {

View file

@ -1,30 +1,19 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.wallpapers; cfg = config.eboskma.wallpapers;
i3SetWallpaper = pkgs.writeShellScript "i3-set-wallpaper" ( i3SetWallpaper = pkgs.writeShellScript "i3-set-wallpaper" (if builtins.isPath cfg.images then
if builtins.isPath cfg.images then ''${pkgs.nitrogen}/bin/nitrogen --set-color=${cfg.backgroundColor} --set-tiled ${cfg.images}''
"${pkgs.nitrogen}/bin/nitrogen --set-color=${cfg.backgroundColor} --set-tiled ${cfg.images}" else
else builtins.concatStringsSep "\n" (map
builtins.concatStringsSep "\n" ( ({ fst, snd }:
map let
( image = fst;
{ fst, snd }: monitor = toString snd;
let in
image = fst; ''${pkgs.nitrogen}/bin/nitrogen --head=${monitor} --set-color=${cfg.backgroundColor} --set-tiled ${image}'')
monitor = toString snd; (zipLists cfg.images (builtins.genList (x: x) (builtins.length cfg.images)))));
in
"${pkgs.nitrogen}/bin/nitrogen --head=${monitor} --set-color=${cfg.backgroundColor} --set-tiled ${image}"
)
(zipLists cfg.images (builtins.genList (x: x) (builtins.length cfg.images)))
)
);
wallpaperConfig = { wallpaperConfig = {
options = { options = {
@ -40,11 +29,7 @@ let
extension = mkOption { extension = mkOption {
description = "The extension of the wallpaper"; description = "The extension of the wallpaper";
type = types.enum [ type = types.enum [ "jpg" "png" "gif" ];
"jpg"
"png"
"gif"
];
}; };
}; };
}; };

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.programs.waybar; cfg = config.eboskma.programs.waybar;
in in
{ {
@ -94,7 +92,7 @@ in
}; };
"sway/mode" = { "sway/mode" = {
format = ''<span style="italic">󰁌 {}</span>''; # Icon: arrow_expand_all format = "<span style=\"italic\">󰁌 {}</span>"; # Icon: arrow_expand_all
tooltip = false; tooltip = false;
}; };
@ -151,11 +149,7 @@ in
phone = ""; # Icon: phone phone = ""; # Icon: phone
portable = ""; # Icon: phone portable = ""; # Icon: phone
car = ""; # Icon: car car = ""; # Icon: car
default = [ default = [ "󰕿" "󰖀" "󰕾" ]; # Icons: volume_low volume_medium volume_high
"󰕿"
"󰖀"
"󰕾"
]; # Icons: volume_low volume_medium volume_high
}; };
on-click = "${pkgs.pavucontrol}/bin/pavucontrol"; on-click = "${pkgs.pavucontrol}/bin/pavucontrol";
on-click-middle = "${pkgs.helvum}/bin/helvum"; on-click-middle = "${pkgs.helvum}/bin/helvum";
@ -182,7 +176,7 @@ in
spacing = 10; spacing = 10;
}; };
"idle_inhibitor" = { "idle_inhibitor" = {
format = ''<span size="large">{icon}</span>''; format = "<span size=\"large\">{icon}</span>";
format-icons = { format-icons = {
activated = "󰛐"; activated = "󰛐";
deactivated = "󰛑"; deactivated = "󰛑";

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.services.xbanish; cfg = config.eboskma.services.xbanish;

View file

@ -1,12 +1,12 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.programs.zathura; cfg = config.eboskma.programs.zathura;
in in
{ {
options.eboskma.programs.zathura = { options.eboskma.programs.zathura = { enable = mkEnableOption "activate zathura"; };
enable = mkEnableOption "activate zathura";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.zathura = { programs.zathura = {

View file

@ -3,10 +3,7 @@ with lib;
let let
cfg = config.eboskma.programs.zellij; cfg = config.eboskma.programs.zellij;
placeholders = [ placeholders = [ "@COPY_COMMAND@" "@SCROLLBACK_EDITOR@" ];
"@COPY_COMMAND@"
"@SCROLLBACK_EDITOR@"
];
replacements = [ replacements = [
cfg.copyCommand cfg.copyCommand
"${config.eboskma.programs.emacs.package}/bin/emacsclient" "${config.eboskma.programs.emacs.package}/bin/emacsclient"

View file

@ -1,9 +1,16 @@
let let
krops = builtins.fetchGit { url = "https://cgit.krebsco.de/krops/"; }; krops = builtins.fetchGit {
url = "https://cgit.krebsco.de/krops/";
};
lib = import "${krops}/lib"; lib = import "${krops}/lib";
pkgs = import "${krops}/pkgs" { }; pkgs = import "${krops}/pkgs" { };
source = _name: lib.evalSource [ { machine-config.file = toString ./.; } ]; source = _name:
lib.evalSource [
{
machine-config.file = toString ./.;
}
];
command = targetPath: '' command = targetPath: ''
nix-shell -p git --run ' nix-shell -p git --run '
@ -12,8 +19,7 @@ let
' '
''; '';
createHost = createHost = name: target:
name: target:
pkgs.krops.writeCommand "deploy-${name}" { pkgs.krops.writeCommand "deploy-${name}" {
inherit command; inherit command;
source = source name; source = source name;

View file

@ -1,26 +1,21 @@
{ self, nixpkgs, ... }@inputs: { self, nixpkgs, ... }@inputs:
rec { rec {
defSystem = defSystem = system: systemConfig: deployConfig:
system: systemConfig: deployConfig:
nixpkgs.lib.nixosSystem { nixpkgs.lib.nixosSystem {
system = "${system}"; system = "${system}";
modules = modules = (systemModules system systemConfig) ++ (nixpkgs.lib.optional (deployConfig != null) { _module.args.nixinate = deployConfig; });
(systemModules system systemConfig)
++ (nixpkgs.lib.optional (deployConfig != null) { _module.args.nixinate = deployConfig; });
}; };
systemModules = systemModules = system: systemConfig:
system: systemConfig: builtins.attrValues self.nixosModules ++ [
builtins.attrValues self.nixosModules
++ [
{ _module.args.inputs = inputs; } { _module.args.inputs = inputs; }
{ _module.args.self-overlay = self.overlays.default; } { _module.args.self-overlay = self.overlays.default; }
{ {
nix.nixPath = [ "nixpkgs=${nixpkgs}" ]; nix.nixPath = [ "nixpkgs=${nixpkgs}" ];
nixpkgs = { nixpkgs =
overlays = {
[ overlays = [
self.overlays.default self.overlays.default
inputs.attic.overlays.default inputs.attic.overlays.default
inputs.emacs-overlay.overlay inputs.emacs-overlay.overlay
@ -29,16 +24,17 @@ rec {
inputs.nil.overlays.default inputs.nil.overlays.default
inputs.pamedia.overlays.${system} inputs.pamedia.overlays.${system}
inputs.rust-overlay.overlays.default inputs.rust-overlay.overlays.default
] ] ++ nixpkgs.lib.optional (system == "aarch64-linux")
++ nixpkgs.lib.optional (system == "aarch64-linux") ( (_final: super: {
_final: super: { makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; }); } makeModulesClosure = x:
); super.makeModulesClosure (x // { allowMissing = true; });
});
config = { config = {
allowUnfree = true; allowUnfree = true;
firefox.speechSynthesisSupport = true; firefox.speechSynthesisSupport = true;
};
}; };
};
home-manager = { home-manager = {
useUserPackages = true; useUserPackages = true;
useGlobalPkgs = true; useGlobalPkgs = true;
@ -52,5 +48,6 @@ rec {
inputs.sops.nixosModules.sops inputs.sops.nixosModules.sops
inputs.sunshine.nixosModules.sunshine inputs.sunshine.nixosModules.sunshine
]; ];
} }

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
../../users/root ../../users/root

View file

@ -1,6 +1,5 @@
{ self, nixos-hardware, ... }: { self, nixos-hardware, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
{ {
virtualisation.oci-containers.containers = { virtualisation.oci-containers.containers = {
@ -37,7 +32,9 @@ with lib;
environment = { environment = {
LIBVA_DRIVER_NAME = "iHD"; LIBVA_DRIVER_NAME = "iHD";
}; };
environmentFiles = [ config.sops.secrets.frigate.path ]; environmentFiles = [
config.sops.secrets.frigate.path
];
}; };
}; };

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,5 +1,4 @@
{ pkgs, config, ... }: { pkgs, config, ... }: {
{
services.gitea-actions-runner = { services.gitea-actions-runner = {
package = pkgs.forgejo-actions-runner; package = pkgs.forgejo-actions-runner;
@ -9,7 +8,9 @@
enable = true; enable = true;
url = "https://git.datarift.nl"; url = "https://git.datarift.nl";
tokenFile = config.sops.secrets.runner-nix-token.path; tokenFile = config.sops.secrets.runner-nix-token.path;
labels = [ "nix:docker://ghcr.io/eboskma/forgejo-nix-runner:latest" ]; labels = [
"nix:docker://ghcr.io/eboskma/forgejo-nix-runner:latest"
];
settings = { settings = {
log = { log = {
level = "info"; level = "info";

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
borgJob = name: { borgJob = name: {
@ -40,5 +35,6 @@ in
}; };
}; };
environment.systemPackages = [ pkgs.borgbackup ]; environment.systemPackages = [ pkgs.borgbackup ];
} }

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
forgejoCfg = config.services.forgejo; forgejoCfg = config.services.forgejo;
in in
{ {

View file

@ -1,4 +1,4 @@
{ self, ... }@inputs: { self, ... } @ inputs:
{ modulesPath, lib, ... }: { modulesPath, lib, ... }:
# let # let
# pkgs = self.inputs.nixpkgs.legacyPackages.x86_64-linux; # pkgs = self.inputs.nixpkgs.legacyPackages.x86_64-linux;
@ -42,34 +42,16 @@
interfaces = { interfaces = {
eth0 = { eth0 = {
ipv4.addresses = [ ipv4.addresses = [
{ { address = "159.69.211.175"; prefixLength = 32; }
address = "159.69.211.175";
prefixLength = 32;
}
]; ];
ipv6.addresses = [ ipv6.addresses = [
{ { address = "2a01:4f8:1c1e:5fb2::1"; prefixLength = 64; }
address = "2a01:4f8:1c1e:5fb2::1"; { address = "fe80::9400:2ff:fe12:a2eb"; prefixLength = 64; }
prefixLength = 64;
}
{
address = "fe80::9400:2ff:fe12:a2eb";
prefixLength = 64;
}
];
ipv4.routes = [
{
address = "172.31.1.1";
prefixLength = 32;
}
];
ipv6.routes = [
{
address = "fe80::1";
prefixLength = 128;
}
]; ];
ipv4.routes = [{ address = "172.31.1.1"; prefixLength = 32; }];
ipv6.routes = [{ address = "fe80::1"; prefixLength = 128; }];
}; };
}; };
}; };
@ -78,20 +60,12 @@
tmp.cleanOnBoot = true; tmp.cleanOnBoot = true;
loader.grub.device = "/dev/sda"; loader.grub.device = "/dev/sda";
initrd = { initrd = {
availableKernelModules = [ availableKernelModules = [ "ata_piix" "uhci_hcd" "xen_blkfront" "vmw_pvscsi" ];
"ata_piix"
"uhci_hcd"
"xen_blkfront"
"vmw_pvscsi"
];
kernelModules = [ "nvme" ]; kernelModules = [ "nvme" ];
}; };
}; };
fileSystems."/" = { fileSystems."/" = { device = "/dev/sda1"; fsType = "ext4"; };
device = "/dev/sda1";
fsType = "ext4";
};
zramSwap.enable = true; zramSwap.enable = true;
### END Hetzner stuff ### END Hetzner stuff
@ -105,6 +79,7 @@
ATTR{address}=="96:00:02:12:a2:eb", NAME="eth0" ATTR{address}=="96:00:02:12:a2:eb", NAME="eth0"
''; '';
openssh = { openssh = {
enable = true; enable = true;
settings = { settings = {

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, lib, ... }: { modulesPath, lib, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
../../users/root ../../users/root
@ -64,7 +63,9 @@
}; };
}; };
tmpfiles.rules = [ "L /dev/kmsg - - - - /dev/console" ]; tmpfiles.rules = [
"L /dev/kmsg - - - - /dev/console"
];
}; };
security = { security = {
@ -76,6 +77,7 @@
sudo.enable = false; sudo.enable = false;
}; };
sops.defaultSopsFile = ./secrets.yaml; sops.defaultSopsFile = ./secrets.yaml;
sops.secrets = { }; sops.secrets = { };

View file

@ -1,9 +1,4 @@
{ { nixos-hardware, nix-ld-rs, attic, ... }:
nixos-hardware,
nix-ld-rs,
attic,
...
}:
{ pkgs, config, ... }: { pkgs, config, ... }:
{ {
imports = [ imports = [
@ -77,6 +72,7 @@
systemd.enable = true; systemd.enable = true;
}; };
fileSystems = { fileSystems = {
"/" = { "/" = {
device = "/dev/disk/by-uuid/42065c7e-d0aa-4de8-a913-014cf59d48ac"; device = "/dev/disk/by-uuid/42065c7e-d0aa-4de8-a913-014cf59d48ac";
@ -94,7 +90,7 @@
}; };
}; };
swapDevices = [ { device = "/dev/disk/by-uuid/d93788f7-1b94-4687-8313-055d17f42b7e"; } ]; swapDevices = [{ device = "/dev/disk/by-uuid/d93788f7-1b94-4687-8313-055d17f42b7e"; }];
# high-resolution display # high-resolution display
# hardware.video.hidpi.enable = lib.mkDefault true; # hardware.video.hidpi.enable = lib.mkDefault true;
@ -106,23 +102,11 @@
hardware.i2c.enable = true; hardware.i2c.enable = true;
boot = { boot = {
initrd.availableKernelModules = [ initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
"nvme"
"xhci_pci"
"ahci"
"usb_storage"
"usbhid"
"sd_mod"
];
initrd.kernelModules = [ ]; initrd.kernelModules = [ ];
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;
kernelModules = [ kernelModules = [ "kvm-amd" "apple-mfi-fastcharge" "zenpower" "nf_nat_ftp" ];
"kvm-amd"
"apple-mfi-fastcharge"
"zenpower"
"nf_nat_ftp"
];
kernelParams = [ "amd_pstate.shared_mem=1" ]; kernelParams = [ "amd_pstate.shared_mem=1" ];
extraModulePackages = with config.boot.kernelPackages; [ extraModulePackages = with config.boot.kernelPackages; [
cpupower cpupower
@ -152,10 +136,7 @@
}; };
firewall = { firewall = {
trustedInterfaces = [ trustedInterfaces = [ "lo" "tailscale0" ];
"lo"
"tailscale0"
];
allowedTCPPorts = [ allowedTCPPorts = [
# NFS # NFS
111 111
@ -200,32 +181,21 @@
allowedTCPPortRanges = [ allowedTCPPortRanges = [
# Sunshine # Sunshine
{ { from = 47984; to = 47990; }
from = 47984;
to = 47990;
}
# Sonos / noson # Sonos / noson
{ { from = 1400; to = 1410; }
from = 1400;
to = 1410;
}
]; ];
allowedUDPPortRanges = [ allowedUDPPortRanges = [
# Sunshine # Sunshine
{ { from = 47998; to = 48000; }
from = 47998;
to = 48000;
}
# Sonos / noson / pulseaudio # Sonos / noson / pulseaudio
{ { from = 1400; to = 1410; }
from = 1400;
to = 1410;
}
]; ];
}; };
}; };
security = { security = {
sudo-rs = { sudo-rs = {
enable = true; enable = true;
@ -259,12 +229,7 @@
{ {
wireguardPeerConfig = { wireguardPeerConfig = {
PublicKey = "6faxlUG8+F7uVrKk/OJqqy5k2+OzrhXc/cV6Zsfbl0c="; PublicKey = "6faxlUG8+F7uVrKk/OJqqy5k2+OzrhXc/cV6Zsfbl0c=";
AllowedIPs = [ AllowedIPs = [ "192.168.4.0/23" "192.168.6.0/24" "192.168.7.0/24" "192.168.8.0/24" ];
"192.168.4.0/23"
"192.168.6.0/24"
"192.168.7.0/24"
"192.168.8.0/24"
];
Endpoint = "212.45.34.195:51820"; Endpoint = "212.45.34.195:51820";
PersistentKeepalive = 25; PersistentKeepalive = 25;
}; };
@ -295,20 +260,20 @@
networkConfig = { networkConfig = {
DHCP = "no"; DHCP = "no";
DNS = "192.168.4.1"; DNS = "192.168.4.1";
Domains = [ Domains = [ "bedum.horus.nu" "internal.horus.nu" ];
"bedum.horus.nu"
"internal.horus.nu"
];
}; };
address = [ "10.10.4.2/24" ]; address = [
"10.10.4.2/24"
];
routes = [ routes = [
{ {
routeConfig = { routeConfig =
Destination = "192.168.4.0/23"; {
Scope = "link"; Destination = "192.168.4.0/23";
}; Scope = "link";
};
} }
{ {
routeConfig = { routeConfig = {
@ -317,16 +282,18 @@
}; };
} }
{ {
routeConfig = { routeConfig =
Destination = "192.168.7.0/24"; {
Scope = "link"; Destination = "192.168.7.0/24";
}; Scope = "link";
};
} }
{ {
routeConfig = { routeConfig =
Destination = "192.168.8.0/24"; {
Scope = "link"; Destination = "192.168.8.0/24";
}; Scope = "link";
};
} }
]; ];
}; };

View file

@ -1,9 +1,4 @@
{ { pkgs, config, inputs, ... }:
pkgs,
config,
inputs,
...
}:
let let
mkK3sNode = name: isServer: ipv4Address: ipv6Address: macAddress: { mkK3sNode = name: isServer: ipv4Address: ipv6Address: macAddress: {
config = { config = {
@ -41,13 +36,11 @@ let
} }
]; ];
interfaces = [ interfaces = [{
{ type = "tap";
type = "tap"; id = "vm-${name}";
id = "vm-${name}"; mac = macAddress;
mac = macAddress; }];
}
];
hypervisor = "cloud-hypervisor"; hypervisor = "cloud-hypervisor";
}; };
@ -63,12 +56,10 @@ let
openssh = { openssh = {
enable = true; enable = true;
hostKeys = [ hostKeys = [{
{ type = "ed25519";
type = "ed25519"; path = "/etc/ssh/ssh_host_ed25519_key";
path = "/etc/ssh/ssh_host_ed25519_key"; }];
}
];
}; };
}; };
@ -124,7 +115,9 @@ in
{ addressConfig.Address = "10.128.0.1/24"; } { addressConfig.Address = "10.128.0.1/24"; }
{ addressConfig.Address = "fd12:3456:789a::1/64"; } { addressConfig.Address = "fd12:3456:789a::1/64"; }
]; ];
ipv6Prefixes = [ { ipv6PrefixConfig.Prefix = "fd12:3456:789a::/64"; } ]; ipv6Prefixes = [
{ ipv6PrefixConfig.Prefix = "fd12:3456:789a::/64"; }
];
}; };
networks."11-microvm" = { networks."11-microvm" = {
@ -140,41 +133,14 @@ in
internalInterfaces = [ "microvm" ]; internalInterfaces = [ "microvm" ];
forwardPorts = [ forwardPorts = [
{ { proto = "tcp"; sourcePort = 6443; destination = "10.128.0.2:6443"; }
proto = "tcp"; { proto = "tcp"; sourcePort = 6443; destination = "10.128.0.3:6443"; }
sourcePort = 6443; { proto = "tcp"; sourcePort = 6443; destination = "10.128.0.4:6443"; }
destination = "10.128.0.2:6443"; { proto = "tcp"; sourcePort = 6443; destination = "fd12:3456:789a::2:6443"; }
} { proto = "tcp"; sourcePort = 6443; destination = "fd12:3456:789a::3:6443"; }
{ { proto = "tcp"; sourcePort = 6443; destination = "fd12:3456:789a::4:6443"; }
proto = "tcp";
sourcePort = 6443;
destination = "10.128.0.3:6443";
}
{
proto = "tcp";
sourcePort = 6443;
destination = "10.128.0.4:6443";
}
{
proto = "tcp";
sourcePort = 6443;
destination = "fd12:3456:789a::2:6443";
}
{
proto = "tcp";
sourcePort = 6443;
destination = "fd12:3456:789a::3:6443";
}
{
proto = "tcp";
sourcePort = 6443;
destination = "fd12:3456:789a::4:6443";
}
]; ];
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [ kubectl kubernetes-helm ];
kubectl
kubernetes-helm
];
} }

View file

@ -1,24 +1,19 @@
{ { nixos-hardware, microvm, nix-ld-rs, attic, ... }:
nixos-hardware,
microvm,
nix-ld-rs,
attic,
...
}:
{ pkgs, config, ... }: { pkgs, config, ... }:
{ {
imports = [ imports =
# Include the results of the hardware scan. [
nixos-hardware.nixosModules.common-cpu-amd # Include the results of the hardware scan.
nixos-hardware.nixosModules.common-cpu-amd-pstate nixos-hardware.nixosModules.common-cpu-amd
nixos-hardware.nixosModules.common-pc-ssd nixos-hardware.nixosModules.common-cpu-amd-pstate
nixos-hardware.nixosModules.common-pc-ssd
microvm.nixosModules.host microvm.nixosModules.host
attic.nixosModules.atticd attic.nixosModules.atticd
../../users/erwin ../../users/erwin
../../users/root ../../users/root
]; ];
# nixpkgs.config.allowUnfree = true; # nixpkgs.config.allowUnfree = true;
@ -80,7 +75,9 @@
}; };
kanata = { kanata = {
enable = true; enable = true;
devices = [ "/dev/input/by-id/usb-04d9_USB-HID_Keyboard-event-kbd" ]; devices = [
"/dev/input/by-id/usb-04d9_USB-HID_Keyboard-event-kbd"
];
}; };
lightdm.enable = false; lightdm.enable = false;
networking.enable = true; networking.enable = true;
@ -115,7 +112,9 @@
}; };
}; };
swapDevices = [ { device = "/dev/disk/by-label/swap"; } ]; swapDevices =
[{ device = "/dev/disk/by-label/swap"; }];
hardware = { hardware = {
enableAllFirmware = true; enableAllFirmware = true;
@ -127,34 +126,23 @@
opengl = { opengl = {
driSupport32Bit = true; driSupport32Bit = true;
extraPackages = with pkgs; [ vaapiVdpau ]; extraPackages = with pkgs; [
vaapiVdpau
];
}; };
}; };
# Use the systemd-boot EFI boot loader. # Use the systemd-boot EFI boot loader.
boot = { boot = {
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;
initrd = { initrd = {
availableKernelModules = [ availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
"nvme"
"xhci_pci"
"ahci"
"usb_storage"
"usbhid"
"sd_mod"
];
kernelModules = [ "dm-snapshot" ]; kernelModules = [ "dm-snapshot" ];
}; };
kernelModules = [ kernelModules = [ "kvm-amd" "apple-mfi-fastcharge" "zenpower" ];
"kvm-amd"
"apple-mfi-fastcharge"
"zenpower"
];
# boot.kernelParams = [ "amd_pstate.shared_mem=1" ]; # boot.kernelParams = [ "amd_pstate.shared_mem=1" ];
extraModulePackages = with config.boot.kernelPackages; [ extraModulePackages = with config.boot.kernelPackages; [ zenpower cpupower ];
zenpower
cpupower
];
loader = { loader = {
systemd-boot = { systemd-boot = {
enable = true; enable = true;
@ -182,10 +170,7 @@
nftables.enable = true; nftables.enable = true;
firewall = { firewall = {
trustedInterfaces = [ trustedInterfaces = [ "lo" "tailscale0" ];
"lo"
"tailscale0"
];
allowedTCPPorts = [ allowedTCPPorts = [
# Horus System V2 # Horus System V2
@ -208,7 +193,9 @@
}; };
}; };
microvm.autostart = [ "miniflux" ]; microvm.autostart = [
"miniflux"
];
powerManagement = { powerManagement = {
cpuFreqGovernor = "ondemand"; cpuFreqGovernor = "ondemand";
@ -279,7 +266,9 @@
Name = "microvm"; Name = "microvm";
}; };
addresses = [ { addressConfig.Address = "172.16.0.1/24"; } ]; addresses = [
{ addressConfig.Address = "172.16.0.1/24"; }
];
}; };
"11-microvm" = { "11-microvm" = {
@ -406,7 +395,9 @@
}; };
environment = { environment = {
systemPackages = with pkgs; [ appimage-run ]; systemPackages = with pkgs; [
appimage-run
];
sessionVariables = { sessionVariables = {
WLR_NO_HARDWARE_CURSORS = "1"; WLR_NO_HARDWARE_CURSORS = "1";
@ -430,4 +421,5 @@
# Before changing this value read the documentation for this option # Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "22.11"; # Did you read the comment? system.stateVersion = "22.11"; # Did you read the comment?
} }

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
minioCfg = config.services.minio; minioCfg = config.services.minio;

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,17 +1,5 @@
{ { self, attic, caddy-with-plugins, ... }:
self, { pkgs, modulesPath, lib, config, ... }: {
attic,
caddy-with-plugins,
...
}:
{
pkgs,
modulesPath,
lib,
config,
...
}:
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
attic.nixosModules.atticd attic.nixosModules.atticd
@ -45,10 +33,7 @@
trustedInterfaces = [ "tailscale0" ]; trustedInterfaces = [ "tailscale0" ];
allowPing = true; allowPing = true;
allowedTCPPorts = [ allowedTCPPorts = [ 80 443 ];
80
443
];
}; };
}; };
@ -170,4 +155,5 @@
}; };
system.stateVersion = "24.05"; system.stateVersion = "24.05";
} }

View file

@ -1,9 +1,4 @@
{ { nixos-hardware, disko, nix-ld-rs, ... }:
nixos-hardware,
disko,
nix-ld-rs,
...
}:
{ pkgs, config, ... }: { pkgs, config, ... }:
{ {
imports = [ imports = [
@ -46,6 +41,7 @@
sudo.enable = false; sudo.enable = false;
}; };
boot = { boot = {
loader = { loader = {
systemd-boot = { systemd-boot = {
@ -56,26 +52,12 @@
}; };
initrd = { initrd = {
availableKernelModules = [ availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "ahci" "usb_storage" "usbhid" "sd_mod" "virtio_blk" "virtio_pci" ];
"xhci_pci"
"thunderbolt"
"nvme"
"ahci"
"usb_storage"
"usbhid"
"sd_mod"
"virtio_blk"
"virtio_pci"
];
kernelModules = [ "kvm-intel" ]; kernelModules = [ "kvm-intel" ];
}; };
kernelPackages = pkgs.linuxPackages_latest; kernelPackages = pkgs.linuxPackages_latest;
kernelModules = [ kernelModules = [ "kvm-intel" "dm-thin-pool" "dm-snapshot" ];
"kvm-intel"
"dm-thin-pool"
"dm-snapshot"
];
# From PVE: ro quiet intel_iommu=on i915.enable_gvt=1 cpufreq.default_governor=ondemand # From PVE: ro quiet intel_iommu=on i915.enable_gvt=1 cpufreq.default_governor=ondemand
# kernelParams = [ "intel_iommu=on" "i915.enable_gvt=1" "cpufreq.default_governor=ondemand" ]; # kernelParams = [ "intel_iommu=on" "i915.enable_gvt=1" "cpufreq.default_governor=ondemand" ];

View file

@ -66,5 +66,6 @@
}; };
}; };
}; };
}; };
} }

View file

@ -83,7 +83,9 @@
lvs = { lvs = {
data = { data = {
size = "100%FREE"; size = "100%FREE";
extraArgs = [ "--type=thin-pool" ]; extraArgs = [
"--type=thin-pool"
];
}; };
}; };
}; };

View file

@ -128,5 +128,8 @@
}; };
}; };
networking.firewall.allowedTCPPorts = [ 8443 ]; networking.firewall.allowedTCPPorts = [
8443
];
} }

View file

@ -1,6 +1,5 @@
{ self, caddy-with-plugins, ... }: { self, caddy-with-plugins, ... }:
{ modulesPath, pkgs, ... }: { modulesPath, pkgs, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
../../users/root ../../users/root

View file

@ -63,7 +63,9 @@
security = { security = {
polkit.enable = true; polkit.enable = true;
}; };
environment.systemPackages = with pkgs; [ libraspberrypi ]; environment.systemPackages = with pkgs; [
libraspberrypi
];
system.stateVersion = "23.05"; system.stateVersion = "23.05";
} }

View file

@ -1,10 +1,4 @@
{ { pkgs, config, lib, inputs, ... }:
pkgs,
config,
lib,
inputs,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.users.erwin; cfg = config.eboskma.users.erwin;
@ -55,12 +49,12 @@ in
enable = true; enable = true;
}; };
imports = imports = [
[ ../../modules/options ] ../../modules/options
++ (map (mod: (../../home-manager/modules + "/${mod}")) ( ] ++ (map (mod: (../../home-manager/modules + "/${mod}")) (builtins.attrNames (builtins.readDir ../../home-manager/modules)));
builtins.attrNames (builtins.readDir ../../home-manager/modules)
));
}; };
programs.bandwhich.enable = true; programs.bandwhich.enable = true;
}; };
} }

View file

@ -79,7 +79,9 @@
keyboards = { keyboards = {
code = { code = {
devices = [ "/dev/input/by-id/usb-04d9_USB_Keyboard-event-kbd" ]; devices = [
"/dev/input/by-id/usb-04d9_USB_Keyboard-event-kbd"
];
config = '' config = ''
(defsrc (defsrc

View file

@ -1,12 +1,5 @@
{ { pkgs, config, lib, inputs, ... }:
pkgs, with lib; let
config,
lib,
inputs,
...
}:
with lib;
let
cfg = config.eboskma.users.erwin; cfg = config.eboskma.users.erwin;
in in
{ {
@ -53,27 +46,28 @@ in
stateVersion = "23.05"; stateVersion = "23.05";
packages = with pkgs; [ packages = with pkgs;
atool [
bottom atool
falkon bottom
fd falkon
gnome.nautilus fd
imagemagick gnome.nautilus
imv imagemagick
iotop imv
libnotify iotop
mpv libnotify
nordzy-cursor-theme mpv
quintom-cursor-theme nordzy-cursor-theme
procs quintom-cursor-theme
ripgrep procs
units ripgrep
unzip units
xdg-utils unzip
wl-clipboard xdg-utils
zeal wl-clipboard
]; zeal
];
}; };
xdg = { xdg = {
@ -112,11 +106,7 @@ in
i18n.inputMethod = { i18n.inputMethod = {
enabled = "fcitx5"; enabled = "fcitx5";
fcitx5.addons = with pkgs; [ fcitx5.addons = with pkgs; [ fcitx5-m17n fcitx5-gtk fcitx5-configtool ];
fcitx5-m17n
fcitx5-gtk
fcitx5-configtool
];
}; };
gtk = { gtk = {
@ -132,7 +122,9 @@ in
}; };
gtk3 = { gtk3 = {
bookmarks = [ "file:///home/erwin/workspace" ]; bookmarks = [
"file:///home/erwin/workspace"
];
extraConfig = { extraConfig = {
gtk-application-prefer-dark-theme = 1; gtk-application-prefer-dark-theme = 1;
gtk-cursor-theme-name = "Nordzy-cursors"; gtk-cursor-theme-name = "Nordzy-cursors";
@ -150,14 +142,10 @@ in
command-not-found.enable = true; command-not-found.enable = true;
}; };
imports = imports = [
[ ../../modules/options
../../modules/options inputs.anyrun.nixosModules.home-manager
inputs.anyrun.nixosModules.home-manager ] ++ (map (mod: (../../home-manager/modules + "/${mod}")) (builtins.attrNames (builtins.readDir ../../home-manager/modules)));
]
++ (map (mod: (../../home-manager/modules + "/${mod}")) (
builtins.attrNames (builtins.readDir ../../home-manager/modules)
));
}; };
programs.bandwhich.enable = true; programs.bandwhich.enable = true;

View file

@ -1,11 +1,5 @@
{ self, ... }: { self, ... }:
{ { modulesPath, pkgs, lib, ... }: {
modulesPath,
pkgs,
lib,
...
}:
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
../../users/root ../../users/root
@ -86,6 +80,7 @@
sudo.enable = false; sudo.enable = false;
}; };
sops.defaultSopsFile = ./secrets.yaml; sops.defaultSopsFile = ./secrets.yaml;
sops.secrets = { }; sops.secrets = { };

View file

@ -1,6 +1,8 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.adguard; cfg = config.eboskma.adguard;
in in
{ {
@ -32,10 +34,7 @@ in
systemd.services.adguardhome.serviceConfig.AmbientCapabilities = [ "CAP_NET_RAW" ]; systemd.services.adguardhome.serviceConfig.AmbientCapabilities = [ "CAP_NET_RAW" ];
networking.firewall = { networking.firewall = {
allowedUDPPorts = [ allowedUDPPorts = [ 53 67 ];
53
67
];
}; };
}; };
} }

View file

@ -1,6 +1,5 @@
{ self, ... }: { self, ... }:
{ modulesPath, ... }: { modulesPath, ... }: {
{
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")
@ -17,7 +16,9 @@
server = true; server = true;
}; };
adguard = { adguard = {
upstreams = [ "127.0.0.1:5335" ]; upstreams = [
"127.0.0.1:5335"
];
}; };
nix-common = { nix-common = {
enable = true; enable = true;

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.backscrub; cfg = config.eboskma.backscrub;
in in
{ {
@ -17,7 +15,9 @@ in
boot = { boot = {
extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ]; extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
# Register a v4l2loopback device at boot # Register a v4l2loopback device at boot
kernelModules = [ "v4l2loopback" ]; kernelModules = [
"v4l2loopback"
];
extraModprobeConfig = '' extraModprobeConfig = ''
options v4l2loopback max_buffers=2 options v4l2loopback max_buffers=2

View file

@ -1,5 +1,6 @@
{ mkDerivation, lib }: { mkDerivation, lib }:
mkDerivation { mkDerivation
{
pname = "blink1-udev-rules"; pname = "blink1-udev-rules";
version = "20220531093409"; version = "20220531093409";

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.base; cfg = config.eboskma.base;
qmkUdevRules = pkgs.callPackage ./qmk { qmkUdevRules = pkgs.callPackage ./qmk {
inherit (pkgs.stdenv) mkDerivation; inherit (pkgs.stdenv) mkDerivation;
@ -63,34 +61,28 @@ in
hardware.opengl.enable = true; hardware.opengl.enable = true;
environment.systemPackages = environment.systemPackages = with pkgs; [
with pkgs; btop
[ clinfo
btop config.boot.kernelPackages.cpupower
clinfo dig
config.boot.kernelPackages.cpupower du-dust
dig file
du-dust hexyl
file jaq
hexyl lm_sensors
jaq man-pages
lm_sensors man-pages-posix
man-pages moreutils
man-pages-posix nix-template
moreutils nvd
nix-template pigz
nvd s-tui
pigz stress
s-tui usbutils
stress xh
usbutils zip
xh ] ++ (lib.optionals (pkgs.system == "x86_64-linux") [ rar unrar ]);
zip
]
++ (lib.optionals (pkgs.system == "x86_64-linux") [
rar
unrar
]);
documentation.dev.enable = true; documentation.dev.enable = true;
@ -101,8 +93,7 @@ in
}; };
services.udev = { services.udev = {
packages = packages = (optional cfg.udev-rules.qmk qmkUdevRules)
(optional cfg.udev-rules.qmk qmkUdevRules)
++ (optional cfg.udev-rules.probe-rs probersRules) ++ (optional cfg.udev-rules.probe-rs probersRules)
++ (optional cfg.udev-rules.blink1 blink1Rules) ++ (optional cfg.udev-rules.blink1 blink1Rules)
++ (optional cfg.udev-rules.picotool picotoolRules) ++ (optional cfg.udev-rules.picotool picotoolRules)

View file

@ -16,13 +16,11 @@ mkDerivation {
meta = with lib; { meta = with lib; {
description = "udev rules for Raspberry Pi picotool"; description = "udev rules for Raspberry Pi picotool";
license = licenses.mit; license = licenses.mit;
maintainers = [ maintainers = [{
{ email = "erwin@datarift.nl";
email = "erwin@datarift.nl"; github = "eboskma";
github = "eboskma"; name = "Erwin Boskma";
name = "Erwin Boskma"; }];
}
];
platforms = platforms.linux; platforms = platforms.linux;
homepage = "https://github.com/raspberrypi/picotool"; homepage = "https://github.com/raspberrypi/picotool";
}; };

View file

@ -22,12 +22,10 @@ stdenv.mkDerivation {
homepage = "https://git.gurkan.in/gurkan/nixos-blur-plymouth"; homepage = "https://git.gurkan.in/gurkan/nixos-blur-plymouth";
license = licenses.gpl2; license = licenses.gpl2;
platforms = platforms.linux; platforms = platforms.linux;
maintainers = [ maintainers = [{
{ email = "erwin@datarift.nl";
email = "erwin@datarift.nl"; github = "eboskma";
github = "eboskma"; name = "Erwin Boskma";
name = "Erwin Boskma"; }];
}
];
}; };
} }

View file

@ -1,4 +1,7 @@
{ mkDerivation, lib }: { mkDerivation
, lib
,
}:
mkDerivation { mkDerivation {
pname = "probe-rs-udev-rules"; pname = "probe-rs-udev-rules";
version = "20220312131009"; version = "20220312131009";

View file

@ -84,7 +84,3 @@ SUBSYSTEMS=="usb", ATTRS{idVendor}=="28e9", ATTRS{idProduct}=="0189", TAG+="uacc
# WB32 DFU # WB32 DFU
SUBSYSTEMS=="usb", ATTRS{idVendor}=="342d", ATTRS{idProduct}=="dfa0", TAG+="uaccess" SUBSYSTEMS=="usb", ATTRS{idVendor}=="342d", ATTRS{idProduct}=="dfa0", TAG+="uaccess"
# Kyria Raw HID
SUBSYSTEM=="usb", ATTR{idVendor}=="8d1d", ATTR{idProduct}=="9d9d", TAG+="uaccess"
KERNEL=="hidraw*", ATTRS{idVendor}=="8d1d", ATTRS{idProduct}=="9d9d", TAG+="uaccess"

View file

@ -19,12 +19,10 @@ stdenv.mkDerivation {
homepage = "https://qmk.fm"; homepage = "https://qmk.fm";
license = licenses.gpl2; license = licenses.gpl2;
platforms = platforms.linux; platforms = platforms.linux;
maintainers = [ maintainers = [{
{ email = "erwin@datarift.nl";
email = "erwin@datarift.nl"; github = "eboskma";
github = "eboskma"; name = "Erwin Boskma";
name = "Erwin Boskma"; }];
}
];
}; };
} }

View file

@ -20,12 +20,10 @@ mkDerivation {
homepage = "https://solokeys.com"; homepage = "https://solokeys.com";
license = licenses.mit; license = licenses.mit;
platforms = platforms.linux; platforms = platforms.linux;
maintainers = [ maintainers = [{
{ email = "erwin@datarift.nl";
email = "erwin@datarift.nl"; github = "eboskma";
github = "eboskma"; name = "Erwin Boskma";
name = "Erwin Boskma"; }];
}
];
}; };
} }

View file

@ -1,6 +1,8 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.bluetooth; cfg = config.eboskma.bluetooth;
in in
{ {

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.caddy-proxy; cfg = config.eboskma.caddy-proxy;
@ -64,9 +59,6 @@ in
systemd.services.caddy.serviceConfig.EnvironmentFile = [ config.sops.secrets.caddy-env.path ]; systemd.services.caddy.serviceConfig.EnvironmentFile = [ config.sops.secrets.caddy-env.path ];
networking.firewall.allowedTCPPorts = [ networking.firewall.allowedTCPPorts = [ 80 443 ];
80
443
];
}; };
} }

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.desktop; cfg = config.eboskma.desktop;
in in
{ {
@ -77,19 +75,22 @@ in
environment = { environment = {
sessionVariables = mkMerge [ sessionVariables = mkMerge [
{ SSH_AUTH_SOCK = "\${XDG_RUNTIME_DIR}/keyring/ssh"; } {
(mkIf cfg.wayland { SSH_AUTH_SOCK = ''''${XDG_RUNTIME_DIR}/keyring/ssh'';
_JAVA_AWT_WM_NONREPARENTING = "1"; }
MOZ_ENABLE_WAYLAND = "1"; (mkIf cfg.wayland
MOZ_DBUS_REMOTE = "1"; {
QT_QPA_PLATFORM = "wayland"; _JAVA_AWT_WM_NONREPARENTING = "1";
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; MOZ_ENABLE_WAYLAND = "1";
QT_QPA_PLATFORMTHEME = "qt5ct"; MOZ_DBUS_REMOTE = "1";
GDK_BACKEND = "wayland"; QT_QPA_PLATFORM = "wayland";
SDL_VIDEODRIVER = "wayland"; QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
AMD_VULKAN_ICD = "RADV"; QT_QPA_PLATFORMTHEME = "qt5ct";
NIXOS_OZONE_WL = "1"; GDK_BACKEND = "wayland";
}) SDL_VIDEODRIVER = "wayland";
AMD_VULKAN_ICD = "RADV";
NIXOS_OZONE_WL = "1";
})
]; ];
etc = { etc = {

View file

@ -1,6 +1,5 @@
{ config, lib, ... }: { config, lib, ... }:
with lib; with lib; let
let
cfg = config.eboskma.drone; cfg = config.eboskma.drone;
in in
{ {
@ -23,15 +22,21 @@ in
image = "drone/drone:2"; image = "drone/drone:2";
ports = [ "8100:80" ]; ports = [ "8100:80" ];
volumes = [ "drone_data:/data" ]; volumes = [ "drone_data:/data" ];
environmentFiles = [ config.sops.secrets.drone.path ]; environmentFiles = [
config.sops.secrets.drone.path
];
}; };
drone-runner-docker = { drone-runner-docker = {
autoStart = true; autoStart = true;
image = "drone/drone-runner-docker:1"; image = "drone/drone-runner-docker:1";
ports = [ "3000:3000" ]; ports = [ "3000:3000" ];
volumes = [ "/var/run/docker.sock:/var/run/docker.sock" ]; volumes = [
environmentFiles = [ config.sops.secrets.drone-runner.path ]; "/var/run/docker.sock:/var/run/docker.sock"
];
environmentFiles = [
config.sops.secrets.drone-runner.path
];
}; };
}; };

View file

@ -1,18 +1,14 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.element-web; cfg = config.eboskma.element-web;
matrixClientConfig = pkgs.writeText "element-web.json" (builtins.readFile ./element-web.json); matrixClientConfig = pkgs.writeText "element-web.json" (builtins.readFile ./element-web.json);
in in
{ {
options.eboskma.element-web = { options.eboskma.element-web = { enable = mkEnableOption "activate element-web"; };
enable = mkEnableOption "activate element-web";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
eboskma.podman.enable = true; eboskma.podman.enable = true;
@ -21,8 +17,12 @@ in
element-web = { element-web = {
autoStart = true; autoStart = true;
image = "vectorim/element-web"; image = "vectorim/element-web";
ports = [ "8888:80" ]; ports = [
volumes = [ "${matrixClientConfig}:/app/config.json" ]; "8888:80"
];
volumes = [
"${matrixClientConfig}:/app/config.json"
];
}; };
}; };
}; };

View file

@ -1,11 +1,9 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.fonts; cfg = config.eboskma.fonts;
iosevka-buildplans = builtins.fromTOML (builtins.readFile "${pkgs.iosevka.src}/build-plans.toml"); iosevka-buildplans = builtins.fromTOML (builtins.readFile "${pkgs.iosevka.src}/build-plans.toml");
@ -28,27 +26,18 @@ in
fonts = { fonts = {
fontDir.enable = true; fontDir.enable = true;
packages = packages = with pkgs; [
with pkgs; (nerdfonts.override { fonts = [ "Iosevka" "Meslo" "Noto" ]; })
[ corefonts
(nerdfonts.override { dejavu_fonts
fonts = [ google-fonts
"Iosevka" kochi-substitute
"Meslo" material-icons
"Noto" monaspace
]; noto-fonts-emoji
}) ttf_bitstream_vera
corefonts twitter-color-emoji
dejavu_fonts ] ++ lib.optional cfg.iosevka-aile iosevka-aile;
google-fonts
kochi-substitute
material-icons
monaspace
noto-fonts-emoji
ttf_bitstream_vera
twitter-color-emoji
]
++ lib.optional cfg.iosevka-aile iosevka-aile;
fontconfig = { fontconfig = {
defaultFonts = { defaultFonts = {

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.gnome; cfg = config.eboskma.gnome;
in in
{ {
@ -16,7 +14,9 @@ in
gnomeExtensions.appindicator gnomeExtensions.appindicator
papirus-icon-theme papirus-icon-theme
]; ];
services.udev.packages = with pkgs; [ gnome.gnome-settings-daemon ]; services.udev.packages = with pkgs; [
gnome.gnome-settings-daemon
];
services.gnome = { services.gnome = {
gnome-keyring.enable = true; gnome-keyring.enable = true;
at-spi2-core.enable = true; at-spi2-core.enable = true;

View file

@ -1,11 +1,9 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; with lib; let
let
cfg = config.eboskma.greetd; cfg = config.eboskma.greetd;
steamCfg = config.programs.steam; steamCfg = config.programs.steam;
@ -17,9 +15,7 @@ let
steam-gamescope = steam-gamescope =
let let
exports = builtins.attrValues ( exports = builtins.attrValues (builtins.mapAttrs (n: v: "export ${n}=${v}") steamCfg.gamescopeSession.env);
builtins.mapAttrs (n: v: "export ${n}=${v}") steamCfg.gamescopeSession.env
);
in in
pkgs.writeShellScriptBin "steam-gamescope" '' pkgs.writeShellScriptBin "steam-gamescope" ''
${builtins.concatStringsSep "\n" exports} ${builtins.concatStringsSep "\n" exports}
@ -59,116 +55,107 @@ in
}; };
}; };
config = mkIf cfg.enable { config =
services.greetd = { mkIf cfg.enable
enable = true; {
restart = true; services.greetd = {
settings = { enable = true;
default_session = { restart = true;
command = "${pkgs.sway}/bin/sway --unsupported-gpu --config /etc/greetd/sway-config"; settings = {
}; default_session = {
}; command = "${pkgs.sway}/bin/sway --unsupported-gpu --config /etc/greetd/sway-config";
};
programs.regreet = {
enable = false;
settings = {
background = {
path = cfg.wallpaper;
fit = "Cover";
};
GTK = {
application_prefer_dark_theme = true;
theme_name = "elementary";
cursor_theme = "elementary";
icon_theme_name = "elementary";
font_name = "Iosevka Aile 16";
};
commands = {
reboot = [
"systemctl"
"reboot"
];
poweroff = [
"systemctl"
"poweroff"
];
};
};
};
security.pam.services.greetd.u2fAuth = false;
# exec "${pkgs.greetd.regreet}/bin/regreet; swaymsg exit"
networking.firewall.allowedTCPPorts = lib.mkIf (cfg.wayvnc && !config.services.tailscale.enable) [
5900
];
environment = {
systemPackages = with pkgs; [
pantheon.elementary-gtk-theme
pantheon.elementary-icon-theme
];
etc = {
"greetd/sway-config" = {
text = lib.concatStringsSep "\n" (
(lib.optional cfg.wayvnc "exec ${pkgs.wayvnc}/bin/wayvnc 0.0.0.0")
++ [
''
exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l -s /etc/greetd/gtkgreet.css -b ${cfg.wallpaper}; swaymsg exit"
include /etc/sway/config.d/*
''
]
++ (mapAttrsToList inputStr cfg.input)
++ (mapAttrsToList outputStr cfg.output)
);
user = "greeter";
group = "greeter";
};
"greetd/environments" = {
text = concatStringsSep "\n" (
(optional cfg.sway "${swaySession}")
++ (optional cfg.steam "${steam-gamescope}")
++ [ "${pkgs.bash}/bin/bash" ]
);
user = "greeter";
group = "greeter";
};
"greetd/gtkgreet.css" = {
text = style;
user = "greeter";
group = "greeter";
};
"sway/config.d/systemd-env.conf" = {
text = ''
exec_always --no-startup-id systemctl --user import-environment ${envVars}
exec_always --no-startup-id dbus-update-activation-environment --systemd ${envVars}
'';
};
"xdg/gtk-3.0/settings.ini" = {
text = generators.toINI { } {
Settings = {
gtk-theme-name = "elementary";
gtk-icon-theme-name = "elementary";
gtk-cursor-theme-name = "elementary";
gtk-application-prefer-dark-theme = "true";
}; };
}; };
}; };
"xdg/gtk-4.0/settings.ini" = {
text = generators.toINI { } { programs.regreet = {
Settings = { enable = false;
gtk-theme-name = "elementary"; settings = {
gtk-icon-theme-name = "elementary"; background = {
gtk-cursor-theme-name = "elementary"; path = cfg.wallpaper;
gtk-application-prefer-dark-theme = "true"; fit = "Cover";
};
GTK = {
application_prefer_dark_theme = true;
theme_name = "elementary";
cursor_theme = "elementary";
icon_theme_name = "elementary";
font_name = "Iosevka Aile 16";
};
commands = {
reboot = [ "systemctl" "reboot" ];
poweroff = [ "systemctl" "poweroff" ];
};
};
};
security.pam.services.greetd.u2fAuth = false;
# exec "${pkgs.greetd.regreet}/bin/regreet; swaymsg exit"
networking.firewall.allowedTCPPorts = lib.mkIf (cfg.wayvnc && !config.services.tailscale.enable) [ 5900 ];
environment = {
systemPackages = with pkgs; [ pantheon.elementary-gtk-theme pantheon.elementary-icon-theme ];
etc = {
"greetd/sway-config" = {
text = lib.concatStringsSep "\n"
((lib.optional cfg.wayvnc "exec ${pkgs.wayvnc}/bin/wayvnc 0.0.0.0") ++
[
''
exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l -s /etc/greetd/gtkgreet.css -b ${cfg.wallpaper}; swaymsg exit"
include /etc/sway/config.d/*
''
]
++ (mapAttrsToList inputStr cfg.input)
++ (mapAttrsToList outputStr cfg.output));
user = "greeter";
group = "greeter";
};
"greetd/environments" = {
text = concatStringsSep "\n" ((optional cfg.sway "${swaySession}")
++ (optional cfg.steam "${steam-gamescope}")
++ [
"${pkgs.bash}/bin/bash"
]);
user = "greeter";
group = "greeter";
};
"greetd/gtkgreet.css" = {
text = style;
user = "greeter";
group = "greeter";
};
"sway/config.d/systemd-env.conf" = {
text = ''
exec_always --no-startup-id systemctl --user import-environment ${envVars}
exec_always --no-startup-id dbus-update-activation-environment --systemd ${envVars}
'';
};
"xdg/gtk-3.0/settings.ini" = {
text = generators.toINI { } {
Settings = {
gtk-theme-name = "elementary";
gtk-icon-theme-name = "elementary";
gtk-cursor-theme-name = "elementary";
gtk-application-prefer-dark-theme = "true";
};
};
};
"xdg/gtk-4.0/settings.ini" = {
text = generators.toINI { } {
Settings = {
gtk-theme-name = "elementary";
gtk-icon-theme-name = "elementary";
gtk-cursor-theme-name = "elementary";
gtk-application-prefer-dark-theme = "true";
};
};
}; };
}; };
}; };
}; };
};
};
} }

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.headscale; cfg = config.eboskma.headscale;
@ -74,10 +69,7 @@ in
security.acme.acceptTerms = true; security.acme.acceptTerms = true;
networking.firewall.allowedTCPPorts = [ networking.firewall.allowedTCPPorts = [ 80 443 ];
80
443
];
environment.systemPackages = [ pkgs.headscale ]; environment.systemPackages = [ pkgs.headscale ];

View file

@ -1,17 +1,10 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.k3s; cfg = config.eboskma.k3s;
in in
{ {
options.eboskma.k3s = { options.eboskma.k3s = { enable = mkEnableOption "k3s"; };
enable = mkEnableOption "k3s";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
services.k3s = { services.k3s = {
@ -19,9 +12,6 @@ in
extraFlags = "--tls-san=10.0.0.4 --tls-san=100.106.117.132"; extraFlags = "--tls-san=10.0.0.4 --tls-san=100.106.117.132";
}; };
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [ kubectl kubernetes-helm ];
kubectl
kubernetes-helm
];
}; };
} }

View file

@ -54,5 +54,6 @@ in
}; };
}; };
}; };
}; };
} }

View file

@ -1,9 +1,4 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.keycloak; cfg = config.eboskma.keycloak;
@ -27,12 +22,11 @@ let
mkdir $out mkdir $out
cp -r $src/theme/keywind/* $out/ cp -r $src/theme/keywind/* $out/
''; '';
}; };
in in
{ {
options.eboskma.keycloak = { options.eboskma.keycloak = { enable = mkEnableOption "keycloak"; };
enable = mkEnableOption "keycloak";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
services.keycloak = { services.keycloak = {
@ -61,11 +55,13 @@ in
inherit (pkgs.maven) buildMavenPackage; inherit (pkgs.maven) buildMavenPackage;
keycloak = config.services.keycloak.package; keycloak = config.services.keycloak.package;
}) })
(pkgs.callPackage ./phasetwo-admin-ui.nix { inherit (pkgs) stdenv fetchFromGitHub; }) (pkgs.callPackage ./phasetwo-admin-ui.nix {
inherit (pkgs) stdenv fetchFromGitHub;
})
]; ];
}; };
services.caddy = { services. caddy = {
enable = true; enable = true;
email = "erwin@datarift.nl"; email = "erwin@datarift.nl";
@ -89,9 +85,6 @@ in
security.acme.acceptTerms = true; security.acme.acceptTerms = true;
networking.firewall.allowedTCPPorts = [ networking.firewall.allowedTCPPorts = [ 80 443 ];
80
443
];
}; };
} }

View file

@ -1,7 +1,6 @@
{ { buildMavenPackage
buildMavenPackage, , fetchFromGitHub
fetchFromGitHub, , keycloak
keycloak,
}: }:
let let
inherit (keycloak) version; inherit (keycloak) version;

View file

@ -1,4 +1,6 @@
{ buildMavenPackage, fetchFromGitHub }: { buildMavenPackage
, fetchFromGitHub
}:
let let
version = "0.49"; version = "0.49";
in in
@ -24,4 +26,5 @@ buildMavenPackage {
installPhase = '' installPhase = ''
install -D target/keycloak-orgs-${version}.jar $out/keycloak-orgs-${version}.jar install -D target/keycloak-orgs-${version}.jar $out/keycloak-orgs-${version}.jar
''; '';
} }

View file

@ -1,4 +1,6 @@
{ stdenv, fetchFromGitHub }: { stdenv
, fetchFromGitHub
}:
let let
version = "23.0.3.1703879005"; version = "23.0.3.1703879005";
jarVersion = "23.0.1"; jarVersion = "23.0.1";

View file

@ -4,9 +4,7 @@ let
cfg = config.eboskma.klipper; cfg = config.eboskma.klipper;
in in
{ {
options.eboskma.klipper = { options.eboskma.klipper = { enable = mkEnableOption "klipper"; };
enable = mkEnableOption "klipper";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
services = { services = {
@ -67,7 +65,7 @@ in
enable_pin = "!PG0"; enable_pin = "!PG0";
rotation_distance = 34.043; rotation_distance = 34.043;
microsteps = 16; microsteps = 16;
nozzle_diameter = 0.4; nozzle_diameter = 0.400;
filament_diameter = 1.75; filament_diameter = 1.75;
max_extrude_only_distance = 150; max_extrude_only_distance = 150;
heater_pin = "PE4"; heater_pin = "PE4";
@ -76,7 +74,7 @@ in
control = "pid"; control = "pid";
pid_Kp = 12.33; pid_Kp = 12.33;
pid_Ki = 0.51; pid_Ki = 0.51;
pid_Kd = 74.5; pid_Kd = 74.50;
min_temp = 0; min_temp = 0;
max_temp = 250; max_temp = 250;
max_extrude_cross_section = 5; max_extrude_cross_section = 5;
@ -171,5 +169,6 @@ in
hostName = config.networking.hostName; hostName = config.networking.hostName;
}; };
}; };
}; };
} }

View file

@ -1,17 +1,10 @@
{ { pkgs, config, lib, ... }:
pkgs,
config,
lib,
...
}:
with lib; with lib;
let let
cfg = config.eboskma.libvirtd; cfg = config.eboskma.libvirtd;
in in
{ {
options.eboskma.libvirtd = { options.eboskma.libvirtd = { enable = mkEnableOption "libvirtd"; };
enable = mkEnableOption "libvirtd";
};
config = mkIf cfg.enable { config = mkIf cfg.enable {
virtualisation.libvirtd = { virtualisation.libvirtd = {

View file

@ -1,6 +1,8 @@
{ config, lib, ... }: { config
with lib; , lib
let , ...
}:
with lib; let
cfg = config.eboskma.livebook; cfg = config.eboskma.livebook;
in in
{ {
@ -23,7 +25,9 @@ in
livebook = { livebook = {
autoStart = true; autoStart = true;
image = "livebook/livebook"; image = "livebook/livebook";
environmentFiles = [ config.sops.secrets.livebook-password.path ]; environmentFiles = [
config.sops.secrets.livebook-password.path
];
ports = [ ports = [
"8080:8080" "8080:8080"
"8081:8081" "8081:8081"

Some files were not shown because too many files have changed in this diff Show more