this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

feat(agent): NixOS module to inject the agent to installers

Khue Doan 6ae16864 a2ea40db

+115 -1
+88 -1
examples/flake.lock
··· 20 20 "type": "github" 21 21 } 22 22 }, 23 + "flake-utils": { 24 + "inputs": { 25 + "systems": "systems" 26 + }, 27 + "locked": { 28 + "lastModified": 1731533236, 29 + "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", 30 + "owner": "numtide", 31 + "repo": "flake-utils", 32 + "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", 33 + "type": "github" 34 + }, 35 + "original": { 36 + "owner": "numtide", 37 + "repo": "flake-utils", 38 + "type": "github" 39 + } 40 + }, 41 + "gomod2nix": { 42 + "inputs": { 43 + "flake-utils": "flake-utils", 44 + "nixpkgs": [ 45 + "nixie", 46 + "nixpkgs" 47 + ] 48 + }, 49 + "locked": { 50 + "lastModified": 1756047880, 51 + "narHash": "sha256-JeuGh9kA1SPL70fnvpLxkIkCWpTjtoPaus3jzvdna0k=", 52 + "owner": "nix-community", 53 + "repo": "gomod2nix", 54 + "rev": "47d628dc3b506bd28632e47280c6b89d3496909d", 55 + "type": "github" 56 + }, 57 + "original": { 58 + "owner": "nix-community", 59 + "repo": "gomod2nix", 60 + "type": "github" 61 + } 62 + }, 63 + "nixie": { 64 + "inputs": { 65 + "gomod2nix": "gomod2nix", 66 + "nixpkgs": "nixpkgs" 67 + }, 68 + "locked": { 69 + "path": "..", 70 + "type": "path" 71 + }, 72 + "original": { 73 + "path": "..", 74 + "type": "path" 75 + }, 76 + "parent": [] 77 + }, 23 78 "nixpkgs": { 24 79 "locked": { 25 80 "lastModified": 1759580034, 26 81 "narHash": "sha256-YWo57PL7mGZU7D4WeKFMiW4ex/O6ZolUS6UNBHTZfkI=", 82 + "owner": "NixOS", 83 + "repo": "nixpkgs", 84 + "rev": "3bcc93c5f7a4b30335d31f21e2f1281cba68c318", 85 + "type": "github" 86 + }, 87 + "original": { 88 + "owner": "NixOS", 89 + "ref": "nixos-25.05", 90 + "repo": "nixpkgs", 91 + "type": "github" 92 + } 93 + }, 94 + "nixpkgs_2": { 95 + "locked": { 96 + "lastModified": 1759580034, 97 + "narHash": "sha256-YWo57PL7mGZU7D4WeKFMiW4ex/O6ZolUS6UNBHTZfkI=", 27 98 "owner": "nixos", 28 99 "repo": "nixpkgs", 29 100 "rev": "3bcc93c5f7a4b30335d31f21e2f1281cba68c318", ··· 39 110 "root": { 40 111 "inputs": { 41 112 "disko": "disko", 42 - "nixpkgs": "nixpkgs" 113 + "nixie": "nixie", 114 + "nixpkgs": "nixpkgs_2" 115 + } 116 + }, 117 + "systems": { 118 + "locked": { 119 + "lastModified": 1681028828, 120 + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 121 + "owner": "nix-systems", 122 + "repo": "default", 123 + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 124 + "type": "github" 125 + }, 126 + "original": { 127 + "owner": "nix-systems", 128 + "repo": "default", 129 + "type": "github" 43 130 } 44 131 } 45 132 },
+7
examples/flake.nix
··· 7 7 url = "github:nix-community/disko"; 8 8 inputs.nixpkgs.follows = "nixpkgs"; 9 9 }; 10 + nixie = { 11 + # TODO change this to a remote URL if you're building a custom installer 12 + # url = "github:khuedoan/nixie"; 13 + url = "path:.."; 14 + }; 10 15 }; 11 16 12 17 outputs = ··· 14 19 self, 15 20 nixpkgs, 16 21 disko, 22 + nixie, 17 23 }: 18 24 { 19 25 nixosConfigurations = { ··· 21 27 system = "x86_64-linux"; 22 28 modules = [ 23 29 ./installer.nix 30 + nixie.nixosModules.nixie-agent 24 31 ]; 25 32 }; 26 33 machine1 = nixpkgs.lib.nixosSystem {
+20
flake.nix
··· 37 37 { 38 38 packages.${system}.default = app; 39 39 40 + nixosModules.nixie-agent = 41 + { 42 + config, 43 + lib, 44 + pkgs, 45 + ... 46 + }: 47 + { 48 + systemd.services.nixie-agent = { 49 + description = "Nixie Agent"; 50 + wantedBy = [ "multi-user.target" ]; 51 + serviceConfig = { 52 + # TODO we can probably refine the package to nixie-agent only, 53 + # which should reduce ~12MB on the installer 54 + ExecStart = "${self.packages.${system}.default}/bin/nixie-agent"; 55 + Restart = "on-failure"; 56 + }; 57 + }; 58 + }; 59 + 40 60 devShells.${system}.default = pkgs.mkShell { 41 61 packages = [ 42 62 goEnv