haccfiles/pkgs/keytracker/frontend.nix
stuebinm 35e2e6529d
keytracker: fix a lot of things
Apparently, keytracker expects a toml file as config that may or may not be
an instance of an entirely different specification of the spec than the one
python understands.
2021-03-25 00:23:32 +01:00

26 lines
573 B
Nix

{ stdenv
, fetchgit
, ...}:
stdenv.mkDerivation rec {
pname = "keytracker-frontend";
version = "0.0.1";
src = (fetchgit {
url = "https://gitlab.infra4future.de/octycs/keytracker";
rev = "2e83366913732029e8a5913f121df969172244ed";
sha256 = "sha256-ty8m/ITR2gmui3dIJX04FkGT/9SGuirrALyWaNaNwhE=";
}).outPath + "/frontend";
apiUrl = "http://chaski.stuebinm.eu:3030";
buildPhase = ''
substituteInPlace assets/main.js --replace "http://localhost:5000" $apiUrl
rm Readme.md
'';
installPhase = ''
mkdir -p $out
cp -r * $out
'';
}