pgadmin4: 7.0 -> 7.1
Upstream has changed their `yarn.lock` file format to v2. This introduces complications with nixpkgs, which needs the v1 file format. There is also a number of problems with the v2 version (e.g. reproducibility or missing integrity fields) which makes the direct use of v2 lockfile impossible. Due to this change, we will need to convert the lockfile beforehand and add it to nixpkgs. Due to issues with reproducibility it isn't feasable to convert the lockfile within the `pgadmin` derivation. For this commit I added the converted `yarn.lock` file and will add the corresponding update script, once #231687 has been merged. (This adds the tool to convert most of the v2 file to v1 and adds metadata to the lockfile) Signed-off-by: Florian Brandes <florian.brandes@posteo.de>
This commit is contained in:
@@ -14,13 +14,14 @@
|
||||
|
||||
let
|
||||
pname = "pgadmin";
|
||||
version = "7.0";
|
||||
version = "7.1";
|
||||
yarnSha256 = "sha256-9iuD0cy0PEtx9Jc626LtE0sAOtP451TGlFKGtC8Tjs4=";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "pgadmin-org";
|
||||
repo = "pgadmin4";
|
||||
rev = "REL-${lib.versions.major version}_${lib.versions.minor version}";
|
||||
hash = "sha256-m2mO37qNjrznpdKeFHq6yE8cZx4sHBvPB2RHUtS1Uis=";
|
||||
hash = "sha256-oqOjWfmBJNqCCSyKzbdJkdNql7Him2HgAcRovWtjfbE=";
|
||||
};
|
||||
|
||||
# keep the scope, as it is used throughout the derivation and tests
|
||||
@@ -28,8 +29,8 @@ let
|
||||
pythonPackages = python3.pkgs.overrideScope (final: prev: rec { });
|
||||
|
||||
offlineCache = fetchYarnDeps {
|
||||
yarnLock = src + "/web/yarn.lock";
|
||||
hash = "sha256-cnn7CJcnT+TUeeZoeJVX3bO85vuJmVrO7CPR/CYTCS0=";
|
||||
yarnLock = ./yarn.lock;
|
||||
hash = yarnSha256;
|
||||
};
|
||||
|
||||
in
|
||||
@@ -101,6 +102,10 @@ pythonPackages.buildPythonApplication rec {
|
||||
cd web
|
||||
export HOME="$TMPDIR"
|
||||
yarn config --offline set yarn-offline-mirror "${offlineCache}"
|
||||
# replace with converted yarn.lock file
|
||||
rm yarn.lock
|
||||
cp ${./yarn.lock} yarn.lock
|
||||
chmod +w yarn.lock
|
||||
fixup_yarn_lock yarn.lock
|
||||
yarn install --offline --frozen-lockfile --ignore-platform --ignore-scripts --no-progress --non-interactive
|
||||
patchShebangs node_modules/
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user