1{ lib 2, stdenv 3, buildPythonPackage 4, cairocffi 5, django 6, django_tagging 7, fetchPypi 8, gunicorn 9, pyparsing 10, python-memcached 11, pythonOlder 12, pytz 13, six 14, txamqp 15, urllib3 16, whisper 17, whitenoise 18}: 19 20buildPythonPackage rec { 21 pname = "graphite-web"; 22 version = "1.1.10"; 23 format = "setuptools"; 24 25 disabled = pythonOlder "3.7"; 26 27 src = fetchPypi { 28 inherit pname version; 29 hash = "sha256-Pxho1QWo2jJZYAMJx999bbELDVMr7Wp7wsssYPkc01o="; 30 }; 31 32 propagatedBuildInputs = [ 33 cairocffi 34 django 35 django_tagging 36 gunicorn 37 pyparsing 38 python-memcached 39 pytz 40 six 41 txamqp 42 urllib3 43 whisper 44 whitenoise 45 ]; 46 47 postPatch = '' 48 substituteInPlace setup.py \ 49 --replace "Django>=1.8,<3.1" "Django" \ 50 --replace "django-tagging==0.4.3" "django-tagging" 51 ''; 52 53 # Carbon-s default installation is /opt/graphite. This env variable ensures 54 # carbon is installed as a regular Python module. 55 GRAPHITE_NO_PREFIX = "True"; 56 57 preConfigure = '' 58 substituteInPlace webapp/graphite/settings.py \ 59 --replace "join(WEBAPP_DIR, 'content')" "join('$out', 'webapp', 'content')" 60 ''; 61 62 pythonImportsCheck = [ 63 "graphite" 64 ]; 65 66 meta = with lib; { 67 broken = (stdenv.isLinux && stdenv.isAarch64) || stdenv.isDarwin; 68 description = "Enterprise scalable realtime graphing"; 69 homepage = "http://graphiteapp.org/"; 70 license = licenses.asl20; 71 maintainers = with maintainers; [ offline basvandijk ]; 72 }; 73}