{ # hyperhive marketing landing — Zola static site build (#502). # # `nix build` → `result/` is the `public/` Zola dist, ready to drop # under any static-file host. No CI runner needed; the flake is the # validation contract. # # Output shape mirrors `hyperhive/hyperhive`'s flake — hand-rolled # `forAllSystems` helper instead of `flake-utils`. Less ceremony, # one source of truth for the systems list, and consistent with the # rest of the project. description = "hyperhive marketing landing"; inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.11"; outputs = { self, nixpkgs }: let inherit (nixpkgs) lib; systems = [ "aarch64-linux" "x86_64-linux" ]; forAllSystems = f: lib.genAttrs systems ( system: f rec { inherit system; pkgs = nixpkgs.legacyPackages.${system}; } ); in { packages = forAllSystems ( { pkgs, ... }: { # `nix build .#website` → static dist at result/. website = pkgs.stdenv.mkDerivation { pname = "hyperhive-website"; version = self.shortRev or "dev"; src = ./.; nativeBuildInputs = [ pkgs.zola ]; # Zola reads `config.toml` from CWD, writes `public/` next to # it. Build is offline / hermetic — no network access needed # at build time, fits the nix sandbox without extra fetchurls. buildPhase = '' runHook preBuild zola build --output-dir public runHook postBuild ''; installPhase = '' runHook preInstall mkdir -p $out cp -r public/. $out/ runHook postInstall ''; # Static-site dist; no shared libs to patchelf, no executables. dontFixup = true; }; # `nix build` with no attribute → the website dist. default = self.packages.${pkgs.system}.website; } ); # `nix develop` → a shell with zola for local iteration: # `zola serve` runs the dev server with live reload. devShells = forAllSystems ( { pkgs, ... }: { default = pkgs.mkShell { packages = [ pkgs.zola ]; }; } ); }; }