{ "info": { "author": "Fr\u00e9d\u00e9ric Aoustin", "author_email": "fraoustin@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "Intended Audience :: Developers", "Intended Audience :: System Administrators", "License :: OSI Approved :: GNU General Public License v2 (GPLv2)", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.0", "Programming Language :: Python :: 3.1", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Topic :: Software Development :: Build Tools", "Topic :: System :: Software Distribution" ], "description": "pypiweb minimal PyPI server for use with pip\r\n============================================\r\n\r\nIt's a fork of pypi-server (https://github.com/pypiserver/pypiserver)\r\n\r\nAdd a interface pypi web: http///pypi and add manage template\r\n\r\nFor install, use: https://github.com/pypiserver/pypiserver and replace pypi-server command\r\nby pypiweb\r\n\r\nInstallation\r\n------------\r\n\r\n::\r\n\r\n pip install pypiweb\r\n\r\nOr\r\n\r\n::\r\n\r\n git clone https://github.com/fraoustin/pypiweb.git\r\n cd pypiweb\r\n python setup.py install\r\n\r\nUploading packages from sources, remotely\r\n-----------------------------------------\r\nInstead of copying packages directly to the server's folder,\r\nyou may also upload them remotely with a ``python setup.py upload`` command.\r\nCurrently only password-protected uploads are supported!\r\n\r\n#. First make sure you have the *passlib* module installed,\r\n which is needed for parsing the apache *htpasswd* file specified by\r\n the `-P`, `--passwords` option (see next steps)::\r\n\r\n pip install passlib\r\n\r\n#. Create the apache *htpasswd* file with at least one user/password pair\r\n with this command (you'll be prompted for a password)::\r\n\r\n htpasswd -sc .htaccess \r\n\r\n .. Tip::\r\n Read this SO question for running `htpasswd` cmd under *Windows*:\r\n\r\n http://serverfault.com/questions/152950/how-to-create-and-edit-htaccess-and-htpasswd-locally-on-my-computer-and-then-u\r\n\r\n or if you have bogus passwords for an internal service you may use this\r\n public service:\r\n\r\n http://www.htaccesstools.com/htpasswd-generator/\r\n\r\n It is also possible to disable authentication even for uploads.\r\n To avoid lazy security decisions, read help for ``-P`` and ``-a`` options.\r\n\r\n#. You need to restart the server with the `-P` option only once\r\n (but user/password pairs can later be added or updated on the fly)::\r\n\r\n ./pypiweb -p 8080 -P .htaccess ~/packages &\r\n\r\n#. You need change a template::\r\n\r\n ./pypiweb -p 8080 -P .htaccess --add-template mytemplatedir ~/packages &\r\n\r\n#. On client-side, edit or create a `~/.pypirc` file with a similar content::\r\n\r\n [distutils]\r\n index-servers =\r\n pypi\r\n local\r\n\r\n [pypi]\r\n username:\r\n password:\r\n\r\n [local]\r\n repository: http://localhost:8080\r\n username: \r\n password: \r\n\r\n#. Then from within the directory of the python-project you wish to upload,\r\n issue this command::\r\n\r\n python setup.py sdist upload -r local\r\n\r\n.. Tip::\r\n To avoid storing you passwords on disk in clear text, you may either:\r\n - Use the `register` command with the `-r` option, like that::\r\n\r\n python setup.py sdist register -r local upload -r local\r\n\r\n - Use `twine `_ library which\r\n breaks the procedure in two steps.\r\n\r\n\r\nClient-side configurations\r\n--------------------------\r\nAlways specifying the the pypi url on the command line is a bit\r\ncumbersome. Since pypiweb redirects pip/easy_install to the\r\npypi.python.org index if it doesn't have a requested package, it's a\r\ngood idea to configure them to always use your local pypi index.\r\n\r\n`pip`\r\n~~~~~\r\nFor *pip* this can be done by setting the environment variable\r\n`PIP_EXTRA_INDEX_URL` in your `.bashrc`/`.profile`/`.zshrc`::\r\n\r\n export PIP_EXTRA_INDEX_URL=http://localhost:8080/simple/\r\n\r\nor by adding the following lines to `~/.pip/pip.conf`::\r\n\r\n [global]\r\n extra-index-url = http://localhost:8080/simple/\r\n\r\n.. Note::\r\n If you have installed *pypiweb* on a remote url without *https*\r\n you wil receive an \"untrusted\" warning from *pip*, urging you to append\r\n the `--trusted-host` option. You can also include this option permanently\r\n in your configuration-files or environment variables.\r\n\r\nUsing a different WSGI server\r\n-----------------------------\r\n- *pypiweb* ships with it's own copy of bottle.\r\n It's possible to use bottle with different WSGI servers.\r\n\r\n- *pypiweb* chooses any of the\r\n following *paste*, *cherrypy*, *twisted*, *wsgiref* (part of python) if\r\n available.\r\n\r\n- If none of the above servers matches your needs, pypiserver also\r\n exposes an API to get the internal WSGI app, which you can then run\r\n under any WSGI server you like. `pypiweb.app` has the following\r\n interface::\r\n\r\n def app(root=None,\r\n redirect_to_fallback=True,\r\n fallback_url=\"http://pypi.python.org/simple\")\r\n\r\n and returns the WSGI application. `root` is the package directory,\r\n `redirect_to_fallback` specifies whether to redirect to `fallback_url` when\r\n a package is missing.\r\n\r\napache/mod_wsgi\r\n~~~~~~~~~~~~~~~\r\nIn case you're using *apache2* with *mod_wsgi*, the following config-file\r\n(contributed by Thomas Waldmann) can be used::\r\n\r\n # An example pypiserver.wsgi for use with apache2 and mod_wsgi, edit as necessary.\r\n #\r\n # apache virtualhost configuration for mod_wsgi daemon mode:\r\n # Alias /robots.txt /srv/yoursite/htdocs/robots.txt\r\n # WSGIPassAuthorization On\r\n # WSGIScriptAlias / /srv/yoursite/cfg/pypiserver.wsgi\r\n # WSGIDaemonProcess pypisrv user=pypisrv group=pypisrv processes=1 threads=5 maximum-requests=500 umask=0007 display-name=wsgi-pypisrv inactivity-timeout=300\r\n # WSGIProcessGroup pypisrv\r\n\r\n PACKAGES = \"/srv/yoursite/packages\"\r\n HTPASSWD = \"/srv/yoursite/htpasswd\"\r\n TEMPLATE = \"/srv/yoursite/template\"\r\n import pypiweb\r\n application = pypiweb.app(PACKAGES, redirect_to_fallback=True, password_file=HTPASSWD, add_template=TEMPLATE)\r\n\r\nTemplate\r\n~~~~~~~~\r\n\r\nFor change logo for simple, create a directory template/static/images/ and add a file python-logo.png with your logo.\r\n\r\nFor list of template:\r\n\r\n- packages.tpl for url http///packages\r\n- pypiindex.tpl for url http///pypi/\r\n- pypipkg.tpl for url http///pypi/pkg\r\n- simple for url http///simple\r\n- simpleprefix.tpl for url http///simple/prefix\r\n- welcome.tpl for url http///\r\n- static/... for url http///static/...", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://url/of/pypiweb/website", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "pypiweb", "package_url": "https://pypi.org/project/pypiweb/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/pypiweb/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://url/of/pypiweb/website" }, "release_url": "https://pypi.org/project/pypiweb/0.1.1/", "requires_dist": null, "requires_python": null, "summary": "pypiweb description", "version": "0.1.1" }, "last_serial": 1780358, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "ac67c2d4ae4b5188c6e89fa2fd98d877", "sha256": "839b3857246762167363f64639ae43bd5467ce5575fb1b511b7d2f41a8669371" }, "downloads": -1, "filename": "pypiweb-0.1.0.tar.gz", "has_sig": false, "md5_digest": "ac67c2d4ae4b5188c6e89fa2fd98d877", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 68058, "upload_time": "2015-10-16T16:19:01", "url": "https://files.pythonhosted.org/packages/34/07/7c4818e6c349e23eb5f1a2f19f2c97c35e8f06eedfa6b3ffbb62eb818a07/pypiweb-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "33a037904b3a535d3b8d087f6c187c37", "sha256": "2e0a8e1a377e9ffa835f74451a978d051452cedeec1a36a24544a7278b4269c0" }, "downloads": -1, "filename": "pypiweb-0.1.1.tar.gz", "has_sig": false, "md5_digest": "33a037904b3a535d3b8d087f6c187c37", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 68223, "upload_time": "2015-10-21T17:40:02", "url": "https://files.pythonhosted.org/packages/00/06/a7d1f624e3e1f0ad933c525aed34d960d0b678f8414edd1af39913c18e09/pypiweb-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "33a037904b3a535d3b8d087f6c187c37", "sha256": "2e0a8e1a377e9ffa835f74451a978d051452cedeec1a36a24544a7278b4269c0" }, "downloads": -1, "filename": "pypiweb-0.1.1.tar.gz", "has_sig": false, "md5_digest": "33a037904b3a535d3b8d087f6c187c37", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 68223, "upload_time": "2015-10-21T17:40:02", "url": "https://files.pythonhosted.org/packages/00/06/a7d1f624e3e1f0ad933c525aed34d960d0b678f8414edd1af39913c18e09/pypiweb-0.1.1.tar.gz" } ] }