Skyler Grey | 1e2187f | 2023-03-03 22:45:10 +0000 | [diff] [blame] | 1 | { |
| 2 | description = "A flake to deploy and configure Clicks' NixOS server"; |
| 3 | |
| 4 | inputs.deploy-rs.url = "github:serokell/deploy-rs"; |
| 5 | |
| 6 | outputs = { self, nixpkgs, deploy-rs, ... }@inputs: { |
Skyler Grey | 4f3e606 | 2023-03-04 01:29:29 +0000 | [diff] [blame] | 7 | nixosConfigurations.clicks = |
| 8 | let |
| 9 | system = "x86_64-linux"; |
| 10 | pkgs = import nixpkgs { |
| 11 | inherit system; |
| 12 | config.allowUnfree = true; |
| 13 | }; |
| 14 | in |
| 15 | nixpkgs.lib.nixosSystem { |
| 16 | inherit system pkgs; |
| 17 | modules = [ |
| 18 | ./default/configuration.nix |
| 19 | ./default/hardware-configuration.nix |
| 20 | ./modules/mongodb.nix |
| 21 | ./modules/git.nix |
| 22 | ./modules/caddy.nix |
| 23 | ./modules/fuck.nix |
| 24 | ./modules/node.nix |
Skyler Grey | 7e4504e | 2023-03-04 15:19:33 +0000 | [diff] [blame] | 25 | ./modules/kitty.nix |
Skyler Grey | 5dbad00 | 2023-03-04 15:21:51 +0000 | [diff] [blame] | 26 | ./modules/tesseract.nix |
Skyler Grey | 4287618 | 2023-03-05 13:03:42 +0000 | [diff] [blame] | 27 | ./modules/doas.nix |
Skyler Grey | 4f3e606 | 2023-03-04 01:29:29 +0000 | [diff] [blame] | 28 | { |
Skyler Grey | 4f3e606 | 2023-03-04 01:29:29 +0000 | [diff] [blame] | 29 | users.mutableUsers = false; |
| 30 | } |
| 31 | ]; |
Skyler Grey | 1e2187f | 2023-03-03 22:45:10 +0000 | [diff] [blame] | 32 | }; |
Skyler Grey | 1e2187f | 2023-03-03 22:45:10 +0000 | [diff] [blame] | 33 | |
| 34 | deploy.nodes.clicks = { |
Skyler Grey | 4287618 | 2023-03-05 13:03:42 +0000 | [diff] [blame] | 35 | sudo = "doas -u"; |
Skyler Grey | 1e2187f | 2023-03-03 22:45:10 +0000 | [diff] [blame] | 36 | profiles.system = { |
| 37 | remoteBuild = true; |
| 38 | user = "root"; |
| 39 | path = deploy-rs.lib.x86_64-linux.activate.nixos |
| 40 | self.nixosConfigurations.clicks; |
| 41 | }; |
| 42 | hostname = "192.168.89.74"; |
| 43 | profilesOrder = [ "system" ]; |
| 44 | }; |
Skyler Grey | 4f3e606 | 2023-03-04 01:29:29 +0000 | [diff] [blame] | 45 | |
| 46 | formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixpkgs-fmt; |
Skyler Grey | 1e2187f | 2023-03-03 22:45:10 +0000 | [diff] [blame] | 47 | }; |
| 48 | } |