~munksgaard/geomyidae-flake

A nix flake containing a geomyidae service module definition.
Make it clear that geomyidae is a gopher server
Use lib.literalExpression instead of a hardcoded path

refs

master
browse  log 

clone

read-only
https://git.sr.ht/~munksgaard/geomyidae-flake
read/write
git@git.sr.ht:~munksgaard/geomyidae-flake

You can also use your local clone with git send-email.

#Geomyidae flake

This flake packages the gopher-server geomyidae as a NixOS service.

#Example use

Put gph files as described in the geomyidae manual in the src dir and create a flake.nix file containing:

{
  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
  inputs.geomyidae.url = "sourcehut:~munksgaard/geomyidae-flake";

  outputs = { self, nixpkgs, geomyidae } : {

    nixosConfigurations.container = nixpkgs.lib.nixosSystem {
      system = "x86_64-linux";
      modules = [
        ({pkgs , ... }: {
          imports = [ geomyidae.nixosModules.geomyidae ];

          system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev;

          system.stateVersion = "22.11";

          boot.isContainer = true;
          networking.useDHCP = false;
          networking.firewall.allowedTCPPorts = [ 70 ];
          networking.hostName = "geomyidae";

          services.geomyidae = {
            enable = true;
            base = "${pkgs.copyPathToStore ./src}";
          };
        })
      ];
    };

  };
}