diff --git a/pkgs/development/python-modules/seahub/default.nix b/pkgs/development/python-modules/seahub/default.nix new file mode 100644 index 000000000000..3ed0d9acfedc --- /dev/null +++ b/pkgs/development/python-modules/seahub/default.nix @@ -0,0 +1,56 @@ +{ stdenv, lib, fetchFromGitHub, python3Packages, makeWrapper }: + +python3Packages.buildPythonPackage rec { + pname = "seahub"; + version = "8.0.7"; + + src = fetchFromGitHub { + owner = "haiwen"; + repo = "seahub"; + rev = "4f7bb3f617dd847cf0a6b33c0bfb567b44c06059"; # using a fixed revision because upstream may re-tag releases :/ + sha256 = "09d05sxly1bljxxzm77limhwsbg8c4b54fzv3kmaih59pjnjyr03"; + }; + + dontBuild = true; + doCheck = false; # disabled because it requires a ccnet environment + + nativeBuildInputs = [ makeWrapper ]; + + propagatedBuildInputs = with python3Packages; [ + django + future + django-statici18n + django-webpack-loader + django-simple-captcha + django-picklefield + django-formtools + mysqlclient + pillow + python-dateutil + django_compressor + djangorestframework + openpyxl + requests + requests_oauthlib + pyjwt + pycryptodome + qrcode + pysearpc + seaserv + ]; + + installPhase = '' + cp -dr --no-preserve='ownership' . $out/ + wrapProgram $out/manage.py \ + --prefix PYTHONPATH : "$PYTHONPATH:$out/thirdpart:" \ + --prefix PATH : "${python3Packages.python}/bin" + ''; + + meta = with lib; { + homepage = "https://github.com/haiwen/seahub"; + description = "The web end of seafile server"; + license = licenses.asl20; + platforms = platforms.linux; + maintainers = with maintainers; [ greizgh schmittlauch ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index a9f93ac2cba5..a1670ae31b0f 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8317,6 +8317,8 @@ in { seabreeze = callPackage ../development/python-modules/seabreeze { }; + seahub = callPackage ../development/python-modules/seahub { }; + seaserv = toPythonModule pkgs.seafile-server; seccomp = callPackage ../development/python-modules/seccomp { };