{"id":13501191,"url":"https://github.com/gauge-sh/bridge","last_synced_at":"2025-04-11T19:05:18.424Z","repository":{"id":229893096,"uuid":"777931063","full_name":"gauge-sh/bridge","owner":"gauge-sh","description":"Automatic infrastructure for Django","archived":false,"fork":false,"pushed_at":"2024-06-24T16:34:34.000Z","size":4149,"stargazers_count":146,"open_issues_count":2,"forks_count":6,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-08-04T10:04:36.405Z","etag":null,"topics":["cli","developer-tools","devops","devtools","django","open-source","python"],"latest_commit_sha":null,"homepage":"https://gauge-sh.github.io/bridge/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gauge-sh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-03-26T19:13:02.000Z","updated_at":"2024-08-01T18:43:45.000Z","dependencies_parsed_at":"2024-05-15T17:17:46.131Z","dependency_job_id":"d83efea8-4609-4797-8148-751efc01952a","html_url":"https://github.com/gauge-sh/bridge","commit_stats":null,"previous_names":["never-over/bridge-sdk","never-over/bridge"],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauge-sh%2Fbridge","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauge-sh%2Fbridge/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauge-sh%2Fbridge/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gauge-sh%2Fbridge/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gauge-sh","download_url":"https://codeload.github.com/gauge-sh/bridge/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248465311,"owners_count":21108243,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","developer-tools","devops","devtools","django","open-source","python"],"created_at":"2024-07-31T22:01:28.701Z","updated_at":"2025-04-11T19:05:18.396Z","avatar_url":"https://github.com/gauge-sh.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"[![image](https://img.shields.io/pypi/v/python-bridge.svg)](https://pypi.python.org/pypi/python-bridge)\n[![image](https://img.shields.io/pypi/l/python-bridge.svg)](https://pypi.python.org/pypi/python-bridge)\n[![image](https://img.shields.io/pypi/pyversions/python-bridge.svg)](https://pypi.python.org/pypi/python-bridge)\n[![image](https://github.com/gauge-sh/bridge/actions/workflows/ci.yml/badge.svg)](https://github.com/gauge-sh/bridge/actions/workflows/ci.yml)\n[![Checked with pyright](https://microsoft.github.io/pyright/img/pyright_badge.svg)](https://microsoft.github.io/pyright/)\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n# bridge\nFully automate your infrastructure for Django.\n\n![](https://raw.githubusercontent.com/gauge-sh/bridge/main/docs/runserver_demo.gif)\n\n[Full Documentation](https://gauge-sh.github.io/bridge/)\n\n### What is bridge?\nBridge enables you to seamlessly run and deploy all the infrastructure you need for a complete Django project.\n\n- Two lines of copy-paste configuration\n- Local Postgres database automatically configured and connected\n- Local Redis instance automatically configured and connected\n- Local Celery and Celery Flower instance automatically configured and connected\n- Easy one-command deploy configuration to Render\n\n### Installation\nInstall [Docker](https://docs.docker.com/get-docker/) and verify it's running:\n```bash\n\u003e docker version\nClient: ...\n```\nInstall bridge:\n```bash\npip install python-bridge\n```\n### Usage\nAdd the following code to the end of your `settings.py` file (or `DJANGO_SETTINGS_MODULE`):\n```python\nfrom bridge import django\n\ndjango.configure(locals())\n```\n\n\nThe next time you start up your application, bridge will create and configure local infrastructure for you:\n```bash\n\u003e ./manage.py runserver\n\nSetting up service bridge_postgres...\n[12:00:00] ✓ Image postgres:12 pulled\n[12:00:00] ✓ Container bridge_postgres started\n[12:00:00] ✓ bridge_postgres is ready\nService bridge_postgres started!\nSetting up service bridge_redis...\n[12:00:00] ✓ Image redis:7.2.4 pulled\n[12:00:00] ✓ Container bridge_redis started\n[12:00:00] ✓ bridge_redis is ready\nService bridge_redis started!\nSetting up service bridge_celery...\n[12:00:00] ✓ Local worker started\nService bridge_celery started!\nSetting up service bridge_flower...\n[12:00:00] ✓ Flower started\nService bridge_flower started!\nPerforming system checks...\n\nSystem check identified no issues (0 silenced).\nStarting development server at http://127.0.0.1:8000/\nQuit the server with CONTROL-C.\n```\nThat's it! You now have all the local infrastructure you need to run your django application.\n\n### Deploys\nBridge can also handle deployed configuration for your app as well! Simply run:\n```bash\nbridge init render\n```\nYou may be prompted for the entrypoint of your application and settings file if bridge cannot detect them. \nBridge will create all the configuration necessary for you to immediately deploy to [Render](https://render.com/). This includes a Blueprint `render.yaml` as well as build scripts and start scripts for your Django application.\nAfter running `bridge init render`, commit the changes and visit your project on github. You will see the following button at the end of your README in the root of your repository:\n\n![Deploy to Render](https://render.com/images/deploy-to-render-button.svg)\n\nTo deploy your application to the world, simply click the button! Bridge will configure everything needed for Render to deploy and host your app.\n\nIn the future, we'll look into supporting more deployment runtimes such as Heroku, AWS, GCP, Azure, and more.\n\n### FAQ\n\nHow does bridge work?\n- Bridge spins up and runs all the services needed for your infrastructure in the background. Postgres and Redis run in docker containers, while Celery and Celery Flower (which need to understand your application code) run as background processes.\n\nWhat if I don't need all the services that bridge provides?\n- Bridge is designed to be modular. You can configure only the services you need by editing the `bridge.yaml` file that bridge creates in your project root. By default, `enable_postgres: true` and `enable_worker: true` are set, but you can change these to `false` to prevent bridge from configuring Postgres and Celery respectively.\n\nHow can I stop the services that bridge spins up?\n- `bridge stop` will stop all running services.\n\nHow can I access the database directly?\n- Locally, bridge provides access to a psql shell through `bridge db shell`. Remotely, [Render has instructions for connecting](https://docs.render.com/databases#connecting-with-the-external-url). \n\nHow can I access redis directly?\n- Bridge provides access to redis-cli through `bridge redis shell`. Remotely, [Render has instructions for connecting](https://docs.render.com/redis#connecting-using-redis-cli).\n\nHow can I access Celery?\n- Flower is a web interface into all the information you need to debug and work with Celery. By default, bridge will run Flower on http://localhost:5555.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgauge-sh%2Fbridge","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgauge-sh%2Fbridge","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgauge-sh%2Fbridge/lists"}