Skip to content

Commit

Permalink
nix-topology
Browse files Browse the repository at this point in the history
  • Loading branch information
zowoq committed Aug 12, 2024
1 parent 0d916db commit df971d5
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 2 deletions.
3 changes: 2 additions & 1 deletion dev/docs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
};
}
''
cd $files
cp --no-preserve=mode -r $files/* .
cp --no-preserve=mode -r ${config.packages.topology}/* docs
mkdocs build --strict --site-dir $out
'';
docs-linkcheck = pkgs.testers.lycheeLinkCheck rec {
Expand Down
7 changes: 7 additions & 0 deletions docs/hosts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#### Main

[<img src="../main.svg" height="200" width="200" alt="main">](main.svg)

#### Network

[<img src="../network.svg" height="200" width="200" alt="network">](network.svg)
30 changes: 30 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 12 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@
flake-utils.url = "github:numtide/flake-utils";
nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
nix-darwin.url = "github:LnL7/nix-darwin";
nix-topology.inputs.devshell.follows = "empty";
nix-topology.inputs.flake-utils.follows = "flake-utils";
nix-topology.inputs.nixpkgs.follows = "nixpkgs";
nix-topology.inputs.pre-commit-hooks.follows = "empty";
nix-topology.url = "github:oddlama/nix-topology";
nixpkgs-update-github-releases.flake = false;
nixpkgs-update-github-releases.url = "github:nix-community/nixpkgs-update-github-releases";
nixpkgs-update.inputs.mmdoc.follows = "empty";
Expand All @@ -52,7 +57,10 @@
flake-parts.lib.mkFlake { inherit inputs; } {
systems = import inputs.systems;

imports = [ inputs.treefmt-nix.flakeModule ];
imports = [
inputs.nix-topology.flakeModule
inputs.treefmt-nix.flakeModule
];

perSystem =
{
Expand All @@ -77,8 +85,11 @@
_module.args.pkgs = import inputs.nixpkgs {
inherit system;
config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "terraform" ];
overlays = [ inputs.nix-topology.overlays.default ];
};

packages.topology = self.topology.${system}.config.output;

checks =
let
darwinConfigurations = lib.mapAttrs' (
Expand Down
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ nav:
- FAQ: faq.md
- administrators.md
- contact.md
- hosts.md
- security.md

theme:
Expand Down
1 change: 1 addition & 0 deletions modules/nixos/common/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
inputs.sops-nix.nixosModules.sops
inputs.agenix.nixosModules.age
inputs.srvos.nixosModules.server
inputs.nix-topology.nixosModules.default
];

# Hard-link duplicated files
Expand Down

0 comments on commit df971d5

Please sign in to comment.