This repository has been archived on 2026-02-07. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
2026-01-07 18:23:52 +01:00

1.1 KiB

data-smasher

The ./tests/ directory provides an example key and convenience script for testing data propagation. Use ./tests/run-two-nodes.sh to start two nodes, then data can be send to one of them with:

./tests/send-test-data.py 8082 testfile "test"

Run clan service tests with:

nix build .#checks.x86_64-linux.dns-mesher --rebuild --print-build-logs

Services usage:

# Add input
dns-mesher.url = "git+https://git.clan.lol/pinpox/data-smasher";
dns-mesher.inputs.nixpkgs.follows = "nixpkgs";

# ... ther stuff

clan = clan-core.lib.clan {

  modules."@pinpox/dns-mesher" = dns-mesher.clanModules.dns-mesher;

  # Include dns-mesher's custom exports module for endpoints
  exportsModule = dns-mesher.clanExportsModule;

  inventory = {
    instances = {

      dns-mesher = {
        module.input = "self";
        module.name = "@pinpox/dns-mesher";

        # Add the default role to all machines
        roles.default.tags = [ "all" ];

        # Deploy example service that exports an endpoint somewhere
        roles.exampleservice.machines.hostA = { };
      };
    };
  };
};