2023-07-15 17:15:38 +00:00
|
|
|
{ mkYarnPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, fetchYarnDeps
|
|
|
|
, lib
|
|
|
|
}:
|
|
|
|
|
|
|
|
mkYarnPackage rec {
|
|
|
|
pname = "lxd-ui";
|
2023-10-19 13:55:26 +00:00
|
|
|
version = "0.2";
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "canonical";
|
|
|
|
repo = "lxd-ui";
|
2023-10-19 13:55:26 +00:00
|
|
|
rev = "refs/tags/${version}";
|
|
|
|
sha256 = "sha256-DygWNktangFlAqinBm6wWsRLGmX6yjhmRJ2iU0yjcgk=";
|
2023-07-15 17:15:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
packageJSON = ./package.json;
|
|
|
|
offlineCache = fetchYarnDeps {
|
|
|
|
yarnLock = "${src}/yarn.lock";
|
2023-10-19 13:55:26 +00:00
|
|
|
sha256 = "sha256-B1SVCViX1LEFoBLMdFk9qaoayku7Y+zU5c4JEJkLmwE=";
|
2023-07-15 17:15:38 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
yarn --offline build
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
cp -rv deps/lxd-ui/build/ui/ $out
|
|
|
|
'';
|
|
|
|
|
|
|
|
doDist = false;
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Web user interface for LXD.";
|
2023-08-04 22:07:22 +00:00
|
|
|
homepage = "https://github.com/canonical/lxd-ui";
|
2023-07-15 17:15:38 +00:00
|
|
|
license = lib.licenses.gpl3;
|
|
|
|
maintainers = with lib.maintainers; [ jnsgruk ];
|
|
|
|
platforms = lib.platforms.linux;
|
|
|
|
};
|
|
|
|
}
|