Fediversity/deployment/run/tf-single-host/tf-env.nix
Kiara Grouwstra d75eacc996
add a TF http backend to store state, see #515
Signed-off-by: Kiara Grouwstra <kiara@procolix.eu>
2025-10-06 13:07:49 +02:00

31 lines
638 B
Nix

{
lib,
pkgs,
sources ? import ../../../npins,
}:
pkgs.stdenv.mkDerivation {
name = "tf-repo";
src =
with lib.fileset;
toSource {
root = ../../../.;
# don't copy ignored files
fileset = intersection (gitTracked ../../../.) ../../../.;
};
buildInputs = [
(pkgs.callPackage ./tf.nix { inherit sources; })
(pkgs.callPackage ../tf-setup.nix { inherit sources; })
];
buildPhase = ''
runHook preBuild
pushd deployment/run/tf-single-host
source setup
popd
runHook postBuild
'';
installPhase = ''
runHook preInstall
cp -r . $out
runHook postInstall
'';
}