{ "info": { "author": "Benoit Chesneau", "author_email": "benoitc@e-engura.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "Intended Audience :: System Administrators", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Software Development", "Topic :: Software Development :: Libraries :: Application Frameworks" ], "description": "dj-revproxy\n-----------\n\nDjango reverse proxy. Allows you to proxy any website behind a prefix.\n\nRequirements\n------------\n\n- `Python `_ 2.x superior to 2.5 and Django\n- `Django `_ >= 1.2\n- `restkit `_ >= 2.1.2\n\nInstallation\n------------\n\nInstall from sources::\n\n $ python setup.py install\n\nOr from Pypi::\n\n $ easy_install -U dj-revproxy \n\nConfiguration\n-------------\n\nAdd `revproxy` to the list of applications::\n\n INSTALLED_APPS = (\n ...\n 'revproxy'\n )\n\nUsage\n-----\n\nSince 0.2, there is 2 ways to use dj-revproxy.\n\n\n1. Generic view\n+++++++++++++++\n\nYou can use ``proxy_request`` function to proxy any url. You can use it in your code::\n\n proxy_request(request, \"http://example.com\")\n\nThis code will proxy current request to ``http://example.com`` domain.\nThis function can take 5 parameters:\n\n- destination: string, the proxied url. Required\n- path: string, If no path is given it will try to detect the url using\n the prefix if it's given. If not full request.path will be used in\n finl destination url.\n- prefix: string, the prrefix behind we proxy the path\n headers: dict, custom HTTP headers\n- no_redirect: boolean, False by default, do not redirect to \"/\" \n if no path is given\n- decompress: boolean, False by default. If true the proxy will\n decompress the source body if it's gzip encoded.\n\nIt return an instance of ``django.http.HttpResponse``. You can use it directly\nin your urls.py (which is the eaiest way to use). Ex::\n\n (r'^gunicorn(?P.*)', \"revproxy.proxy_request\", {\n \"destination\": \"http://gunicorn.org\"\n }),\n\n2. Configure multiple proxy behind one generic prefix\n+++++++++++++++++++++++++++++++++++++++++++++++++++++\n\nTo configure a proxy add a tupple to the REVPROXY_SETTINGS list::\n\n REVPROXY_SETTINGS = [\n (\"_google\", \"http://google.com\"),\n (\"_friendpaste\", \"http://www.friendpaste.com\"),\n (\"_couchdb\", \"http://127.0.0.1:5984\"),\n ]\n\nThen configure your proxied urls automatically do something like this in\n``urls.py``:: \n from django.conf.urls.defaults import *\n\n import revproxy\n\n urlpatterns = patterns('',\n ...\n (r'^proxy/', include(revproxy.site_proxy.urls)),\n )\n\nWhich will allow you to proxy Google on the url::\n\n http://127.0.0.1:8000/proxy/_google\n\nor even::\n\n ('^proxy/(?P[^\\/]*)(.*)', \"revproxy.site_proxy\"),", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/benoitc/dj-revproxy", "keywords": null, "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "dj-revproxy", "package_url": "https://pypi.org/project/dj-revproxy/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/dj-revproxy/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/benoitc/dj-revproxy" }, "release_url": "https://pypi.org/project/dj-revproxy/0.2.1/", "requires_dist": null, "requires_python": null, "summary": "Django reverse proxy", "version": "0.2.1" }, "last_serial": 789008, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "eb302ae722a6ff01ff304f2a11620b35", "sha256": "7212d17352676cde72e55a9411d2d5d633a58fbeecb07c2797c9d19a99ddb822" }, "downloads": -1, "filename": "dj-revproxy-0.1.0.tar.gz", "has_sig": false, "md5_digest": "eb302ae722a6ff01ff304f2a11620b35", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9157, "upload_time": "2010-10-16T17:58:17", "url": "https://files.pythonhosted.org/packages/2f/14/b56d83e59493da895a9335e82f8fbc681a523a4cf3a8666fc8695f70d9fc/dj-revproxy-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "076abe99d1d1d496b063e817cc1d99bf", "sha256": "0e19827fb5f01d2610be2052d5788bf800ed17980d86e99da68ddb3b5bf38a0f" }, "downloads": -1, "filename": "dj-revproxy-0.1.1.tar.gz", "has_sig": false, "md5_digest": "076abe99d1d1d496b063e817cc1d99bf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10088, "upload_time": "2010-10-16T18:17:26", "url": "https://files.pythonhosted.org/packages/7c/d4/4ea4c1924059706255344016e57386090bfc29d394dbf85e76e45cd00881/dj-revproxy-0.1.1.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "efc0ea36018a2e672949f402701a10d9", "sha256": "355d09a6b53b2f666d9c9a9cccc036701aef054a3bea0a3649ddcac1313ed06d" }, "downloads": -1, "filename": "dj-revproxy-0.2.0.tar.gz", "has_sig": false, "md5_digest": "efc0ea36018a2e672949f402701a10d9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10875, "upload_time": "2010-10-17T15:59:41", "url": "https://files.pythonhosted.org/packages/b1/c3/dc2ff67be608d096d9ac6432e9be3d4dc4a6020af194c68358faebc13b99/dj-revproxy-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "9ef36ae6fcfb5d1d4744018f0e4da6ba", "sha256": "961306082e2f91a701a2858eeee3f50f60eca5e72f9cdb1e69f047502855667e" }, "downloads": -1, "filename": "dj-revproxy-0.2.1.tar.gz", "has_sig": false, "md5_digest": "9ef36ae6fcfb5d1d4744018f0e4da6ba", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9286, "upload_time": "2010-11-09T16:29:45", "url": "https://files.pythonhosted.org/packages/f5/bf/7d2402b7d9dd4a27a115187f90df648454a76d7e531d2f5ac0d59e1c5113/dj-revproxy-0.2.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "9ef36ae6fcfb5d1d4744018f0e4da6ba", "sha256": "961306082e2f91a701a2858eeee3f50f60eca5e72f9cdb1e69f047502855667e" }, "downloads": -1, "filename": "dj-revproxy-0.2.1.tar.gz", "has_sig": false, "md5_digest": "9ef36ae6fcfb5d1d4744018f0e4da6ba", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9286, "upload_time": "2010-11-09T16:29:45", "url": "https://files.pythonhosted.org/packages/f5/bf/7d2402b7d9dd4a27a115187f90df648454a76d7e531d2f5ac0d59e1c5113/dj-revproxy-0.2.1.tar.gz" } ] }