mirror of
https://github.com/Swarsel/.dotfiles.git
synced 2025-12-06 09:07:21 +01:00
refactor: lib, flake.nix
This commit is contained in:
parent
a0f4384034
commit
b71bb5794a
27 changed files with 540 additions and 706 deletions
282
index.html
282
index.html
|
|
@ -3,7 +3,7 @@
|
|||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2024-12-28 Sa 16:43 -->
|
||||
<!-- 2024-12-28 Sa 18:15 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>SwarselSystems: NixOS + Emacs Configuration</title>
|
||||
|
|
@ -221,7 +221,7 @@
|
|||
<li><a href="#h:f881aa05-a670-48dd-a57b-2916abdcb692">3.7. darwinConfigurations</a></li>
|
||||
<li><a href="#h:f881aa05-a670-48dd-a57b-2916abdcb692">3.8. homeConfigurations</a></li>
|
||||
<li><a href="#h:5f6ef553-59f9-4239-b6f3-63d33b57f335">3.9. nixOnDroidConfigurations</a></li>
|
||||
<li><a href="#orgd28d2ce">3.10. topologyConfigurations</a></li>
|
||||
<li><a href="#orgd058157">3.10. topologyConfigurations</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h:02cd20be-1ffa-4904-9d5a-da5a89ba1421">4. System</a>
|
||||
|
|
@ -245,12 +245,12 @@
|
|||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orgd491f98">4.1.3. Utility hosts</a>
|
||||
<li><a href="#orgaaba600">4.1.3. Utility hosts</a>
|
||||
<ul>
|
||||
<li><a href="#org77e9aa9">4.1.3.1. Toto (Physical/VM)</a></li>
|
||||
<li><a href="#org87a675b">4.1.3.1. Toto (Physical/VM)</a></li>
|
||||
<li><a href="#h:8583371d-5d47-468b-84ba-210aad7e2c90">4.1.3.2. drugstore (ISO)</a></li>
|
||||
<li><a href="#h:7056b9a0-f38b-4bca-b2ba-ab34e2d73493">4.1.3.3. Home-manager only (non-NixOS)</a></li>
|
||||
<li><a href="#org2b0d997">4.1.3.4. ChaosTheatre (Demo Physical/VM)</a></li>
|
||||
<li><a href="#org869d7a3">4.1.3.4. ChaosTheatre (Demo Physical/VM)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
@ -275,14 +275,14 @@
|
|||
<li><a href="#h:4d864147-f9ef-46da-9b4f-4e7996a65157">4.2.1.14. update-checker</a></li>
|
||||
<li><a href="#h:a9398c4e-4d3b-4942-b03c-192f9c0517e5">4.2.1.15. github-notifications</a></li>
|
||||
<li><a href="#h:960e539c-2a5a-4e21-b3d4-bcdfc8be8fda">4.2.1.16. screenshare</a></li>
|
||||
<li><a href="#h:74db57ae-0bb9-4257-84be-eddbc85130dd">4.2.1.17. bootstrap</a></li>
|
||||
<li><a href="#orgd873577">4.2.1.18. swarsel-rebuild</a></li>
|
||||
<li><a href="#orgd81a8e9">4.2.1.19. swarsel-install</a></li>
|
||||
<li><a href="#org829f5bd">4.2.1.20. swarsel-postinstall</a></li>
|
||||
<li><a href="#h:74db57ae-0bb9-4257-84be-eddbc85130dd">4.2.1.17. swarsel-bootstrap</a></li>
|
||||
<li><a href="#org7469bc3">4.2.1.18. swarsel-rebuild</a></li>
|
||||
<li><a href="#orge755727">4.2.1.19. swarsel-install</a></li>
|
||||
<li><a href="#org0dbac39">4.2.1.20. swarsel-postinstall</a></li>
|
||||
<li><a href="#h:5ad99997-e54c-4f0b-9ab7-15f76b1e16e1">4.2.1.21. t2ts</a></li>
|
||||
<li><a href="#h:5ad99997-e54c-4f0b-9ab7-15f76b1e16e1">4.2.1.22. ts2t</a></li>
|
||||
<li><a href="#orgcf9834d">4.2.1.23. vershell</a></li>
|
||||
<li><a href="#org33d3655">4.2.1.24. eontimer</a></li>
|
||||
<li><a href="#org3d80a50">4.2.1.23. vershell</a></li>
|
||||
<li><a href="#org83d7b29">4.2.1.24. eontimer</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h:5e3e21e0-57af-4dad-b32f-6400af9b7aab">4.2.2. Overlays (additions, overrides, nixpkgs-stable)</a></li>
|
||||
|
|
@ -293,7 +293,7 @@
|
|||
<li><a href="#h:bd7517c6-0e0a-4063-bc81-e62cd24e7170">4.2.3.1.1. Wallpaper</a></li>
|
||||
<li><a href="#h:c6a138ff-f07f-4cae-95b9-b6daa2b11463">4.2.3.1.2. Hardware</a></li>
|
||||
<li><a href="#h:f4f22166-e345-43e6-b15f-b7f5bb886554">4.2.3.1.3. Setup</a></li>
|
||||
<li><a href="#orgba39c14">4.2.3.1.4. Server</a></li>
|
||||
<li><a href="#org3ba7862">4.2.3.1.4. Server</a></li>
|
||||
<li><a href="#h:45188d3c-9910-480b-beec-d5fd713b05fb">4.2.3.1.5. Input</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
|
@ -370,7 +370,7 @@
|
|||
<li><a href="#h:1bef3914-a258-4585-b232-e0fbe9e7a9b5">4.3.1.29. Podmam (distrobox)</a></li>
|
||||
<li><a href="#h:a5a0d84e-c7b3-4164-a4c7-2e2d8ada69cd">4.3.1.30. Handle lid switch correctly</a></li>
|
||||
<li><a href="#h:adf894d7-b3c6-4b8b-b13f-c28b3a5e1e17">4.3.1.31. Low battery notification</a></li>
|
||||
<li><a href="#orgf0c4047">4.3.1.32. Lanzaboote</a></li>
|
||||
<li><a href="#org9f79b09">4.3.1.32. Lanzaboote</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#h:e492c24a-83a0-4bcb-a084-706f49318651">4.3.2. Server</a>
|
||||
|
|
@ -685,7 +685,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<p>
|
||||
<b>This file has 58511 words spanning 14914 lines and was last revised on 2024-12-28 16:43:06 +0100.</b>
|
||||
<b>This file has 58383 words spanning 14864 lines and was last revised on 2024-12-28 18:15:25 +0100.</b>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
|
@ -738,7 +738,7 @@ This section defines my Emacs configuration. For a while, I considered to use ry
|
|||
</p>
|
||||
|
||||
<p>
|
||||
My emacs is built using the emacs-overlay nix flake, which builds a bleeding edge emacs on wayland (pgtk) with utilities like treesitter support. By executing the below source block, the current build setting can be updated at any time, and you can see my most up-to-date build options (last updated: 2024-12-28 16:43:06 +0100)
|
||||
My emacs is built using the emacs-overlay nix flake, which builds a bleeding edge emacs on wayland (pgtk) with utilities like treesitter support. By executing the below source block, the current build setting can be updated at any time, and you can see my most up-to-date build options (last updated: 2024-12-28 18:15:25 +0100)
|
||||
</p></li>
|
||||
</ul>
|
||||
|
||||
|
|
@ -1552,38 +1552,8 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
let
|
||||
|
||||
inherit (self) outputs;
|
||||
lib = nixpkgs.lib // home-manager.lib;
|
||||
lib = (nixpkgs.lib // home-manager.lib).extend (_: _: { swarselsystems = import ./lib { inherit self lib inputs outputs systems; }; });
|
||||
|
||||
pkgsFor = lib.genAttrs (import systems) (
|
||||
system:
|
||||
import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
}
|
||||
);
|
||||
forEachSystem = f: lib.genAttrs (import systems) (system: f pkgsFor.${system});
|
||||
forAllSystems = lib.genAttrs [
|
||||
"x86_64-linux"
|
||||
"aarch64-linux"
|
||||
"x86_64-darwin"
|
||||
"aarch64-darwin"
|
||||
];
|
||||
mkFullHost = host: isNixos: {
|
||||
${host} =
|
||||
let
|
||||
func = if isNixos then lib.nixosSystem else inputs.nix-darwin.lib.darwinSystem;
|
||||
systemFunc = func;
|
||||
in
|
||||
systemFunc {
|
||||
specialArgs = {
|
||||
inherit inputs outputs self;
|
||||
lib = lib.extend (_: _: { swarselsystems = import ./lib { inherit lib; }; });
|
||||
};
|
||||
modules = [ ./hosts/${if isNixos then "nixos" else "darwin"}/${host} ];
|
||||
};
|
||||
};
|
||||
mkFullHostConfigs = hosts: isNixos: lib.foldl (acc: set: acc // set) { } (lib.map (host: mkFullHost host isNixos) hosts);
|
||||
readHosts = folder: lib.attrNames (builtins.readDir ./hosts/${folder});
|
||||
|
||||
# NixOS modules that can only be used on NixOS systems
|
||||
nixModules = [
|
||||
|
|
@ -1609,13 +1579,6 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
./profiles/common/home
|
||||
];
|
||||
|
||||
# For adding things to _module.args (making arguments available globally)
|
||||
# moduleArgs = [
|
||||
# {
|
||||
# _module.args = { inherit self; };
|
||||
# }
|
||||
# ];
|
||||
|
||||
in
|
||||
{
|
||||
|
||||
|
|
@ -1626,31 +1589,22 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
nixosModules = import ./modules/nixos;
|
||||
homeManagerModules = import ./modules/home;
|
||||
|
||||
packages = forEachSystem (pkgs: import ./pkgs { inherit pkgs; });
|
||||
apps = forAllSystems (system: {
|
||||
default = self.apps.${system}.bootstrap;
|
||||
packages = lib.swarselsystems.forEachSystem (pkgs: import ./pkgs { inherit lib; });
|
||||
|
||||
bootstrap = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.bootstrap}/bin/bootstrap";
|
||||
};
|
||||
|
||||
install = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-install}/bin/swarsel-install";
|
||||
};
|
||||
|
||||
postinstall = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-postinstall}/bin/swarsel-postinstall";
|
||||
};
|
||||
|
||||
rebuild = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-rebuild}/bin/swarsel-rebuild";
|
||||
};
|
||||
apps = lib.swarselsystems.forAllSystems (system: let
|
||||
appNames = [
|
||||
"swarsel-bootstrap"
|
||||
"swarsel-install"
|
||||
"swarsel-rebuild"
|
||||
"swarsel-postinstall"
|
||||
];
|
||||
appSet = lib.swarselsystems.mkApps system appNames self;
|
||||
in {
|
||||
inherit appSet;
|
||||
default = appSet.bootstrap;
|
||||
});
|
||||
devShells = forAllSystems (
|
||||
|
||||
devShells = lib.swarselsystems.forAllSystems (
|
||||
system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
|
|
@ -1673,24 +1627,24 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
};
|
||||
});
|
||||
|
||||
formatter = forEachSystem (pkgs: pkgs.nixpkgs-fmt);
|
||||
checks = forAllSystems (
|
||||
formatter = lib.swarselsystems.forEachSystem (pkgs: pkgs.nixpkgs-fmt);
|
||||
checks = lib.swarselsystems.forAllSystems (
|
||||
system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in
|
||||
import ./checks { inherit self inputs system pkgs; }
|
||||
);
|
||||
overlays = import ./overlays { inherit inputs; };
|
||||
overlays = import ./overlays { inherit pkgs; };
|
||||
|
||||
|
||||
nixosConfigurations =
|
||||
mkFullHostConfigs (readHosts "nixos") true;
|
||||
lib.swarselsystems.mkFullHostConfigs (lib.swarselsystems.readHosts "nixos") true;
|
||||
|
||||
homeConfigurations = {
|
||||
|
||||
"swarsel@home-manager" = inputs.home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = pkgsFor.x86_64-linux;
|
||||
pkgs = lib.swarselsystems.pkgsFor.x86_64-linux;
|
||||
extraSpecialArgs = { inherit inputs outputs; };
|
||||
modules = homeModules ++ mixedModules ++ [
|
||||
./hosts/home-manager
|
||||
|
|
@ -1700,12 +1654,12 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
};
|
||||
|
||||
darwinConfigurations =
|
||||
mkFullHostConfigs (readHosts "darwin") false;
|
||||
lib.swarselsystems.mkFullHostConfigs (lib.swarselsystems.readHosts "darwin") false;
|
||||
|
||||
nixOnDroidConfigurations = {
|
||||
|
||||
magicant = inputs.nix-on-droid.lib.nixOnDroidConfiguration {
|
||||
pkgs = pkgsFor.aarch64-linux;
|
||||
pkgs = lib.swarselsystems.pkgsFor.aarch64-linux;
|
||||
modules = [
|
||||
./hosts/magicant
|
||||
];
|
||||
|
|
@ -1715,7 +1669,7 @@ In <code>outputs = inputs@ [...]</code>, the <code>inputs@</code> makes it so th
|
|||
|
||||
topology =
|
||||
|
||||
forEachSystem (pkgs: import inputs.nix-topology {
|
||||
lib.swarselsystems.forEachSystem (pkgs: import inputs.nix-topology {
|
||||
inherit pkgs;
|
||||
modules = [
|
||||
# Your own file to define global topology. Works in principle like a nixos module but uses different options.
|
||||
|
|
@ -1989,38 +1943,8 @@ The interesting part is in the start:
|
|||
<div class="org-src-container">
|
||||
<pre class="src src-nix">
|
||||
inherit (self) outputs;
|
||||
lib = nixpkgs.lib // home-manager.lib;
|
||||
lib = (nixpkgs.lib // home-manager.lib).extend (_: _: { swarselsystems = import ./lib { inherit self lib inputs outputs systems; }; });
|
||||
|
||||
pkgsFor = lib.genAttrs (import systems) (
|
||||
system:
|
||||
import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
}
|
||||
);
|
||||
forEachSystem = f: lib.genAttrs (import systems) (system: f pkgsFor.${system});
|
||||
forAllSystems = lib.genAttrs [
|
||||
"x86_64-linux"
|
||||
"aarch64-linux"
|
||||
"x86_64-darwin"
|
||||
"aarch64-darwin"
|
||||
];
|
||||
mkFullHost = host: isNixos: {
|
||||
${host} =
|
||||
let
|
||||
func = if isNixos then lib.nixosSystem else inputs.nix-darwin.lib.darwinSystem;
|
||||
systemFunc = func;
|
||||
in
|
||||
systemFunc {
|
||||
specialArgs = {
|
||||
inherit inputs outputs self;
|
||||
lib = lib.extend (_: _: { swarselsystems = import ./lib { inherit lib; }; });
|
||||
};
|
||||
modules = [ ./hosts/${if isNixos then "nixos" else "darwin"}/${host} ];
|
||||
};
|
||||
};
|
||||
mkFullHostConfigs = hosts: isNixos: lib.foldl (acc: set: acc // set) { } (lib.map (host: mkFullHost host isNixos) hosts);
|
||||
readHosts = folder: lib.attrNames (builtins.readDir ./hosts/${folder});
|
||||
|
||||
# NixOS modules that can only be used on NixOS systems
|
||||
nixModules = [
|
||||
|
|
@ -2046,13 +1970,6 @@ mixedModules = [
|
|||
./profiles/common/home
|
||||
];
|
||||
|
||||
# For adding things to _module.args (making arguments available globally)
|
||||
# moduleArgs = [
|
||||
# {
|
||||
# _module.args = { inherit self; };
|
||||
# }
|
||||
# ];
|
||||
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -2094,31 +2011,22 @@ inherit nixModules;
|
|||
nixosModules = import ./modules/nixos;
|
||||
homeManagerModules = import ./modules/home;
|
||||
|
||||
packages = forEachSystem (pkgs: import ./pkgs { inherit pkgs; });
|
||||
apps = forAllSystems (system: {
|
||||
default = self.apps.${system}.bootstrap;
|
||||
packages = lib.swarselsystems.forEachSystem (pkgs: import ./pkgs { inherit lib; });
|
||||
|
||||
bootstrap = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.bootstrap}/bin/bootstrap";
|
||||
};
|
||||
|
||||
install = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-install}/bin/swarsel-install";
|
||||
};
|
||||
|
||||
postinstall = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-postinstall}/bin/swarsel-postinstall";
|
||||
};
|
||||
|
||||
rebuild = {
|
||||
type = "app";
|
||||
program = "${self.packages.${system}.swarsel-rebuild}/bin/swarsel-rebuild";
|
||||
};
|
||||
apps = lib.swarselsystems.forAllSystems (system: let
|
||||
appNames = [
|
||||
"swarsel-bootstrap"
|
||||
"swarsel-install"
|
||||
"swarsel-rebuild"
|
||||
"swarsel-postinstall"
|
||||
];
|
||||
appSet = lib.swarselsystems.mkApps system appNames self;
|
||||
in {
|
||||
inherit appSet;
|
||||
default = appSet.bootstrap;
|
||||
});
|
||||
devShells = forAllSystems (
|
||||
|
||||
devShells = lib.swarselsystems.forAllSystems (
|
||||
system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
|
|
@ -2141,15 +2049,15 @@ devShells = forAllSystems (
|
|||
};
|
||||
});
|
||||
|
||||
formatter = forEachSystem (pkgs: pkgs.nixpkgs-fmt);
|
||||
checks = forAllSystems (
|
||||
formatter = lib.swarselsystems.forEachSystem (pkgs: pkgs.nixpkgs-fmt);
|
||||
checks = lib.swarselsystems.forAllSystems (
|
||||
system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in
|
||||
import ./checks { inherit self inputs system pkgs; }
|
||||
);
|
||||
overlays = import ./overlays { inherit inputs; };
|
||||
overlays = import ./overlays { inherit pkgs; };
|
||||
|
||||
</pre>
|
||||
</div>
|
||||
|
|
@ -2169,7 +2077,7 @@ Note: The preceding <code>nixosConfigurations</code> is found in <a href="#h:aee
|
|||
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">mkFullHostConfigs (readHosts "nixos") true;
|
||||
<pre class="src src-nix">lib.swarselsystems.mkFullHostConfigs (lib.swarselsystems.readHosts "nixos") true;
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -2187,7 +2095,7 @@ Note: The preceding <code>darwinConfigurations</code> is found in <a href="#h:ae
|
|||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">mkFullHostConfigs (readHosts "darwin") false;
|
||||
<pre class="src src-nix">lib.swarselsystems.mkFullHostConfigs (lib.swarselsystems.readHosts "darwin") false;
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -2202,7 +2110,7 @@ In contrast, this defines home-manager systems, which I only have one of, that s
|
|||
<div class="org-src-container">
|
||||
<pre class="src src-nix">
|
||||
"swarsel@home-manager" = inputs.home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = pkgsFor.x86_64-linux;
|
||||
pkgs = lib.swarselsystems.pkgsFor.x86_64-linux;
|
||||
extraSpecialArgs = { inherit inputs outputs; };
|
||||
modules = homeModules ++ mixedModules ++ [
|
||||
./hosts/home-manager
|
||||
|
|
@ -2223,7 +2131,7 @@ Nix on Android also demands an own flake output, which is provided here.
|
|||
<div class="org-src-container">
|
||||
<pre class="src src-nix">
|
||||
magicant = inputs.nix-on-droid.lib.nixOnDroidConfiguration {
|
||||
pkgs = pkgsFor.aarch64-linux;
|
||||
pkgs = lib.swarselsystems.pkgsFor.aarch64-linux;
|
||||
modules = [
|
||||
./hosts/magicant
|
||||
];
|
||||
|
|
@ -2233,12 +2141,12 @@ magicant = inputs.nix-on-droid.lib.nixOnDroidConfiguration {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgd28d2ce" class="outline-3">
|
||||
<h3 id="orgd28d2ce"><span class="section-number-3">3.10.</span> topologyConfigurations</h3>
|
||||
<div id="outline-container-orgd058157" class="outline-3">
|
||||
<h3 id="orgd058157"><span class="section-number-3">3.10.</span> topologyConfigurations</h3>
|
||||
<div class="outline-text-3" id="text-3-10">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">
|
||||
forEachSystem (pkgs: import inputs.nix-topology {
|
||||
lib.swarselsystems.forEachSystem (pkgs: import inputs.nix-topology {
|
||||
inherit pkgs;
|
||||
modules = [
|
||||
# Your own file to define global topology. Works in principle like a nixos module but uses different options.
|
||||
|
|
@ -2826,12 +2734,12 @@ in
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgd491f98" class="outline-4">
|
||||
<h4 id="orgd491f98"><span class="section-number-4">4.1.3.</span> Utility hosts</h4>
|
||||
<div id="outline-container-orgaaba600" class="outline-4">
|
||||
<h4 id="orgaaba600"><span class="section-number-4">4.1.3.</span> Utility hosts</h4>
|
||||
<div class="outline-text-4" id="text-4-1-3">
|
||||
</div>
|
||||
<div id="outline-container-org77e9aa9" class="outline-5">
|
||||
<h5 id="org77e9aa9"><span class="section-number-5">4.1.3.1.</span> Toto (Physical/VM)</h5>
|
||||
<div id="outline-container-org87a675b" class="outline-5">
|
||||
<h5 id="org87a675b"><span class="section-number-5">4.1.3.1.</span> Toto (Physical/VM)</h5>
|
||||
<div class="outline-text-5" id="text-4-1-3-1">
|
||||
<p>
|
||||
This is a slim setup for developing base configuration.
|
||||
|
|
@ -3156,8 +3064,8 @@ This is the "reference implementation" of a setup that runs without NixOS, only
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org2b0d997" class="outline-5">
|
||||
<h5 id="org2b0d997"><span class="section-number-5">4.1.3.4.</span> ChaosTheatre (Demo Physical/VM)</h5>
|
||||
<div id="outline-container-org869d7a3" class="outline-5">
|
||||
<h5 id="org869d7a3"><span class="section-number-5">4.1.3.4.</span> ChaosTheatre (Demo Physical/VM)</h5>
|
||||
<div class="outline-text-5" id="text-4-1-3-4">
|
||||
<p>
|
||||
This is just a demo host. It applies all the configuration found in the common parts of the flake, but disables all secrets-related features (as they would not work without the proper SSH keys).
|
||||
|
|
@ -3265,7 +3173,7 @@ Note: The structure of generating the packages was changed in commit <code>2cf03
|
|||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">{ pkgs, ... }:
|
||||
<pre class="src src-nix">{ lib, ... }:
|
||||
let
|
||||
packageNames = [
|
||||
"pass-fuzzel"
|
||||
|
|
@ -3283,7 +3191,7 @@ let
|
|||
"update-checker"
|
||||
"github-notifications"
|
||||
"screenshare"
|
||||
"bootstrap"
|
||||
"swarsel-bootstrap"
|
||||
"swarsel-rebuild"
|
||||
"swarsel-install"
|
||||
"swarsel-postinstall"
|
||||
|
|
@ -3292,12 +3200,8 @@ let
|
|||
"vershell"
|
||||
"eontimer"
|
||||
];
|
||||
mkPackages = names: builtins.listToAttrs (map (name: {
|
||||
inherit name;
|
||||
value = pkgs.callPackage ./${name} { };
|
||||
}) names);
|
||||
in
|
||||
mkPackages packageNames
|
||||
lib.swarselsystems.mkPackages packageNames
|
||||
|
||||
|
||||
</pre>
|
||||
|
|
@ -3937,7 +3841,7 @@ writeShellApplication {
|
|||
</div>
|
||||
</div>
|
||||
<div id="outline-container-h:74db57ae-0bb9-4257-84be-eddbc85130dd" class="outline-5">
|
||||
<h5 id="h:74db57ae-0bb9-4257-84be-eddbc85130dd"><span class="section-number-5">4.2.1.17.</span> bootstrap</h5>
|
||||
<h5 id="h:74db57ae-0bb9-4257-84be-eddbc85130dd"><span class="section-number-5">4.2.1.17.</span> swarsel-bootstrap</h5>
|
||||
<div class="outline-text-5" id="text-h:74db57ae-0bb9-4257-84be-eddbc85130dd">
|
||||
<p>
|
||||
This program sets up a new NixOS host remotely. It also takes care of secret management on the new host.
|
||||
|
|
@ -4291,16 +4195,16 @@ fi
|
|||
<pre class="src src-nix">{ writeShellApplication, openssh }:
|
||||
|
||||
writeShellApplication {
|
||||
name = "bootstrap";
|
||||
name = "swarsel-bootstrap";
|
||||
runtimeInputs = [ openssh ];
|
||||
text = builtins.readFile ../../scripts/bootstrap.sh;
|
||||
text = builtins.readFile ../../scripts/swarsel-bootstrap.sh;
|
||||
}
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgd873577" class="outline-5">
|
||||
<h5 id="orgd873577"><span class="section-number-5">4.2.1.18.</span> swarsel-rebuild</h5>
|
||||
<div id="outline-container-org7469bc3" class="outline-5">
|
||||
<h5 id="org7469bc3"><span class="section-number-5">4.2.1.18.</span> swarsel-rebuild</h5>
|
||||
<div class="outline-text-5" id="text-4-2-1-18">
|
||||
<p>
|
||||
This program builds a configuration locally.
|
||||
|
|
@ -4411,8 +4315,8 @@ writeShellApplication {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgd81a8e9" class="outline-5">
|
||||
<h5 id="orgd81a8e9"><span class="section-number-5">4.2.1.19.</span> swarsel-install</h5>
|
||||
<div id="outline-container-orge755727" class="outline-5">
|
||||
<h5 id="orge755727"><span class="section-number-5">4.2.1.19.</span> swarsel-install</h5>
|
||||
<div class="outline-text-5" id="text-4-2-1-19">
|
||||
<p>
|
||||
This program sets up a new NixOS host locally.
|
||||
|
|
@ -4599,8 +4503,8 @@ writeShellApplication {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org829f5bd" class="outline-5">
|
||||
<h5 id="org829f5bd"><span class="section-number-5">4.2.1.20.</span> swarsel-postinstall</h5>
|
||||
<div id="outline-container-org0dbac39" class="outline-5">
|
||||
<h5 id="org0dbac39"><span class="section-number-5">4.2.1.20.</span> swarsel-postinstall</h5>
|
||||
<div class="outline-text-5" id="text-4-2-1-20">
|
||||
<p>
|
||||
This program sets up a new NixOS host locally.
|
||||
|
|
@ -4743,8 +4647,8 @@ writeShellApplication {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgcf9834d" class="outline-5">
|
||||
<h5 id="orgcf9834d"><span class="section-number-5">4.2.1.23.</span> vershell</h5>
|
||||
<div id="outline-container-org3d80a50" class="outline-5">
|
||||
<h5 id="org3d80a50"><span class="section-number-5">4.2.1.23.</span> vershell</h5>
|
||||
<div class="outline-text-5" id="text-4-2-1-23">
|
||||
<p>
|
||||
This script allows for quick git branch switching.
|
||||
|
|
@ -4765,8 +4669,8 @@ writeShellApplication {
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org33d3655" class="outline-5">
|
||||
<h5 id="org33d3655"><span class="section-number-5">4.2.1.24.</span> eontimer</h5>
|
||||
<div id="outline-container-org83d7b29" class="outline-5">
|
||||
<h5 id="org83d7b29"><span class="section-number-5">4.2.1.24.</span> eontimer</h5>
|
||||
<div class="outline-text-5" id="text-4-2-1-24">
|
||||
<p>
|
||||
This script allows for quick git branch switching.
|
||||
|
|
@ -4840,10 +4744,10 @@ When adding a new entry here, do not forget to add it in the default output of t
|
|||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">{ inputs, ... }:
|
||||
<pre class="src src-nix">{ inputs, lib, ... }:
|
||||
|
||||
let
|
||||
additions = final: _prev: import ../pkgs { pkgs = final; };
|
||||
additions = final: _prev: import ../pkgs { pkgs = final; inherit lib };
|
||||
modifications = _: _prev: {
|
||||
vesktop = _prev.vesktop.override {
|
||||
withSystemVencord = true;
|
||||
|
|
@ -5045,8 +4949,8 @@ I usually use <code>mutableUsers = false</code> in my NixOS configuration. Howev
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgba39c14" class="outline-6">
|
||||
<h6 id="orgba39c14"><span class="section-number-6">4.2.3.1.4.</span> Server</h6>
|
||||
<div id="outline-container-org3ba7862" class="outline-6">
|
||||
<h6 id="org3ba7862"><span class="section-number-6">4.2.3.1.4.</span> Server</h6>
|
||||
<div class="outline-text-6" id="text-4-2-3-1-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-nix">{ lib, ... }:
|
||||
|
|
@ -7432,8 +7336,8 @@ Since I hide the waybar completely during normal operation, I run the risk of no
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgf0c4047" class="outline-5">
|
||||
<h5 id="orgf0c4047"><span class="section-number-5">4.3.1.32.</span> Lanzaboote</h5>
|
||||
<div id="outline-container-org9f79b09" class="outline-5">
|
||||
<h5 id="org9f79b09"><span class="section-number-5">4.3.1.32.</span> Lanzaboote</h5>
|
||||
<div class="outline-text-5" id="text-4-3-1-32">
|
||||
<p>
|
||||
This dynamically uses systemd boot or Lanzaboote depending on `config.swarselsystems.initialSetup` and `config.swarselsystems.isSecureBoot`.
|
||||
|
|
@ -9964,7 +9868,7 @@ This is just a separate container for derivations defined in <a href="#h:64a5cc1
|
|||
vershell
|
||||
eontimer
|
||||
|
||||
bootstrap
|
||||
swarsel-bootstrap
|
||||
|
||||
(pkgs.writeScriptBin "project" ''
|
||||
#! ${pkgs.bash}/bin/bash
|
||||
|
|
@ -16917,7 +16821,7 @@ Prints a reasuring message to proove good faith."
|
|||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: Leon Schwarzäugl</p>
|
||||
<p class="date">Created: 2024-12-28 Sa 16:43</p>
|
||||
<p class="date">Created: 2024-12-28 Sa 18:15</p>
|
||||
<p class="validation"><a href="https://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||
</div>
|
||||
</body>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue