mirror of
https://git.selfprivacy.org/SelfPrivacy/selfprivacy-nix-repo.git
synced 2024-11-13 06:33:16 +00:00
refactor: Simplify overlay, move to NixOS 22.11
This commit is contained in:
parent
746e8ad4ec
commit
6bcfa9452f
30
default.nix
30
default.nix
|
@ -3,36 +3,8 @@ let
|
|||
in
|
||||
|
||||
self: super: rec {
|
||||
python39 = super.python39.override {
|
||||
packageOverrides = python-self: python-super: {
|
||||
strawberry_graphql = python-super.buildPythonPackage rec {
|
||||
pname = "strawberry-graphql";
|
||||
version = "0.123.0";
|
||||
format = "pyproject";
|
||||
patches = [
|
||||
./strawberry-graphql.patch
|
||||
];
|
||||
propagatedBuildInputs = with self.python39Packages; [
|
||||
typing-extensions
|
||||
graphql-core
|
||||
python-multipart
|
||||
python-dateutil
|
||||
flask
|
||||
pydantic
|
||||
pygments
|
||||
poetry
|
||||
];
|
||||
src = python-super.fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "sha256-KsmZ5Xv8tUg6yBxieAEtvoKoRG60VS+iVGV0X6oCExo=";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
pythonPackages = python39.pkgs;
|
||||
selfprivacy-api = super.callPackage ./pkgs/selfprivacy-api {};
|
||||
selfprivacy-graphql-api = super.callPackage ./pkgs/selfprivacy-graphql-api {
|
||||
nixpkgs = pkgs;
|
||||
pythonPkgs = pythonPackages;
|
||||
pythonPkgs = super.python310Packages;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,53 +0,0 @@
|
|||
{ nixpkgs ? import <nixpkgs> { }, pythonPkgs ? nixpkgs.pkgs.python39Packages }:
|
||||
|
||||
let
|
||||
inherit (nixpkgs) pkgs;
|
||||
inherit pythonPkgs;
|
||||
|
||||
selfprivacy-api =
|
||||
{ buildPythonPackage
|
||||
, flask
|
||||
, flask-restful
|
||||
, setuptools
|
||||
, portalocker
|
||||
, flask-swagger
|
||||
, flask-swagger-ui
|
||||
, pytz
|
||||
, pytest
|
||||
, pytest-mock
|
||||
, pytest-datadir
|
||||
, huey
|
||||
, gevent
|
||||
, mnemonic
|
||||
}:
|
||||
buildPythonPackage rec {
|
||||
pname = "selfprivacy-api";
|
||||
version = "1.2.6";
|
||||
src = builtins.fetchGit {
|
||||
url = "https://git.selfprivacy.org/SelfPrivacy/selfprivacy-rest-api.git";
|
||||
rev = "401dff23fb9223e8a0a4bd3ee942c61e471a07ab";
|
||||
};
|
||||
propagatedBuildInputs = [
|
||||
flask
|
||||
flask-restful
|
||||
setuptools
|
||||
portalocker
|
||||
flask-swagger
|
||||
flask-swagger-ui
|
||||
pytz
|
||||
pytest
|
||||
pytest-mock
|
||||
pytest-datadir
|
||||
huey
|
||||
gevent
|
||||
mnemonic
|
||||
];
|
||||
meta = {
|
||||
description = ''
|
||||
SelfPrivacy Server Management API
|
||||
'';
|
||||
};
|
||||
};
|
||||
drv = pythonPkgs.callPackage selfprivacy-api { };
|
||||
in
|
||||
if pkgs.lib.inNixShell then drv.env else drv
|
|
@ -18,7 +18,7 @@ let
|
|||
, mnemonic
|
||||
, pydantic
|
||||
, typing-extensions
|
||||
, strawberry_graphql
|
||||
, strawberry-graphql
|
||||
, psutil
|
||||
, fastapi
|
||||
, uvicorn
|
||||
|
@ -29,7 +29,7 @@ let
|
|||
version = "2.1.1";
|
||||
src = builtins.fetchGit {
|
||||
url = "https://git.selfprivacy.org/SelfPrivacy/selfprivacy-rest-api.git";
|
||||
rev = "1035f9215d72800a71b4918b71fb4eb633432f5f";
|
||||
rev = "6aadbabbc4da5dca0a704b9b1a0a3ee58e81bca5";
|
||||
};
|
||||
propagatedBuildInputs = [
|
||||
setuptools
|
||||
|
@ -43,7 +43,7 @@ let
|
|||
mnemonic
|
||||
pydantic
|
||||
typing-extensions
|
||||
strawberry_graphql
|
||||
strawberry-graphql
|
||||
psutil
|
||||
fastapi
|
||||
uvicorn
|
||||
|
|
Loading…
Reference in a new issue