{"id":18133363,"url":"https://github.com/nickatnight/cookiecutter-fastapi-backend","last_synced_at":"2025-05-07T22:20:54.877Z","repository":{"id":88883764,"uuid":"595827381","full_name":"nickatnight/cookiecutter-fastapi-backend","owner":"nickatnight","description":":cookie: Cookiecutter template to build and deploy fastapi backends..batteries included","archived":false,"fork":false,"pushed_at":"2024-09-14T23:26:34.000Z","size":149,"stargazers_count":118,"open_issues_count":8,"forks_count":7,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-09-16T03:29:33.402Z","etag":null,"topics":["alembic","asyncpg","cookiecutter","digitalocean","fastapi","nginx","openapi","postgres","postgresql","pre-commit","python"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nickatnight.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":"AUTHORS","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-01-31T22:16:50.000Z","updated_at":"2024-09-14T23:23:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"7dca4968-b0d0-4aa5-b62b-4e0c3c420316","html_url":"https://github.com/nickatnight/cookiecutter-fastapi-backend","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickatnight%2Fcookiecutter-fastapi-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickatnight%2Fcookiecutter-fastapi-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickatnight%2Fcookiecutter-fastapi-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickatnight%2Fcookiecutter-fastapi-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nickatnight","download_url":"https://codeload.github.com/nickatnight/cookiecutter-fastapi-backend/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252962708,"owners_count":21832382,"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":["alembic","asyncpg","cookiecutter","digitalocean","fastapi","nginx","openapi","postgres","postgresql","pre-commit","python"],"created_at":"2024-11-01T13:07:33.487Z","updated_at":"2025-05-07T22:20:54.858Z","avatar_url":"https://github.com/nickatnight.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://github.com/nickatnight/cookiecutter-fastapi-backend/actions\"\u003e\n        \u003cimg alt=\"GitHub Actions status\" src=\"https://github.com/nickatnight/cookiecutter-fastapi-backend/actions/workflows/main.yml/badge.svg\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://github.com/nickatnight/cookiecutter-fastapi-backend/releases\"\u003e\u003cimg alt=\"Release Status\" src=\"https://img.shields.io/github/v/release/nickatnight/cookiecutter-fastapi-backend\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://github.com/nickatnight/cookiecutter-fastapi-backend/blob/master/LICENSE\"\u003e\n        \u003cimg alt=\"License Shield\" src=\"https://img.shields.io/github/license/nickatnight/cookiecutter-fastapi-backend\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n# cookiecutter-fastapi-backend\n:cookie: [Cookiecutter](https://github.com/cookiecutter/cookiecutter) template to build and deploy fastapi backends..batteries included.\n\n## Quickstart\nInstall the latest Cookiecutter if you haven't installed it yet (this requires Cookiecutter 1.4.0 or higher):\n```sh\npip install cookiecutter\n```\n\nGenerate project:\n```sh\ncookiecutter https://github.com/nickatnight/cookiecutter-fastapi-backend.git\n```\n\n## Features\n* :whale: **Docker \u0026 Docker Compose** integration and optimization for [local development](https://docs.docker.com/compose/). Fast bundles using build stages and [Poetry](https://python-poetry.org/)\n* :computer: **Production ready** Python web server using [FastAPI](https://fastapi.tiangolo.com/)\n* :pencil2: **SQLModel** [Library](https://sqlmodel.tiangolo.com/) for interacting with SQL databases from Python code, with Python objects. It is designed to be intuitive, easy to use, highly compatible, and robust\n* :light_rail: **Alembic** Lightweight database migration tool for usage with the [SQLAlchemy](https://alembic.sqlalchemy.org/en/latest/) Database Toolkit for Python\n* :globe_with_meridians: **NGINX** High Performance Load Balancer, [Web Server](https://www.nginx.com/), \u0026 Reverse Proxy\n* :lock: **Let's Encrypt** A free, automated, and open [certificate authority](https://letsencrypt.org/) (CA), provided by the Internet Security Research Group (ISRG)...with automatic cert renewal\n* :floppy_disk: **postgresql** Powerful open source [object-relational](https://www.postgresql.org/) database\n* :convenience_store: **Redis** In-memory data structure [store](https://redis.io/), used as a distributed, in-memory key–value database, cache and message broker\n* :seedling: **Celery** [Asynchronous](https://docs.celeryq.dev/en/stable/getting-started/introduction.html) task or job queue\n* :inbox_tray: **Continuous Integration/Deployment** Modular [GitHub Actions](https://github.com/features/actions) to lint, build, test, and deploy to DigitalOcean cloud\n* :leftwards_arrow_with_hook: **pre-commit** [Git hooks](https://pre-commit.com/) to maintain code quality using modern tooling (ruff, black, isort)\n\n## Input Variables\nThe generator (cookiecutter) will ask you for some data, you might want to have at hand before generating the project.\n\nThe input variables, with their default values (some auto generated) are:\n\n* `project_name`: The name of the project\n* `project_slug`: The development friendly name of the project. By default, based on the project name\n* `project_slug_db`: The database friendly name of the project. By default, based on the project name\n* `author_email`: The authors email...used for certbot\n* `py_version`: The version of Python to install. Options are `3.9`, `3.10`, and `3.11`\n* `db_container_name`: The name of the database container. Default `db`\n* `backend_container_name`: The name of the backend container. Default `backend`\n* `use_celery`: Whether to use Celery/Beat for asynchronous/scheduled tasks.\n* `nginx_container_name`: The name of the nginx web server container. Default `nginx`\n* `doctl_version`: The version name of [DigitalOcean Command Line Interface](https://docs.digitalocean.com/reference/doctl/) to use. Default `1.92.0`\n* `github_username`: The username of the GitHub user. Used for badge display in generated project `README.md`\n* `deployments`: Include `docker-compose` files needed for deployment step in GitHub Action. Options are `y` or `n`\n\n\n## More Details\nAfter using this generator, your new project (the directory created) will contain an extensive `README.md` with instructions for development, deployment, etc. You can view it [here](/%7B%7B%20cookiecutter.project_slug%20%7D%7D/README.md)\n\n## Development\nThis project uses [Poetry](https://python-poetry.org/docs/#osx--linux--bashonwindows-install-instructions) to manage dev environment.  Once installed:\n1. install packages with `poetry install`\n2. run tests with `poetry run pytest tests`\n\nPre-commit:\n1. Install pre-commit hooks with `pre-commit install`\n2. Run hooks with `pre-commit run --all-files`\n\n## Acknowledgements\n- [tiangolo](https://github.com/tiangolo/full-stack-fastapi-postgresql) for the FastAPI project\n- [jonra](https://github.com/jonra1993/fastapi-alembic-sqlmodel-async) for the Alembic/SQLModel knowledge\n- [nemd](https://github.com/nemd/) / [ironhalik](https://github.com/ironhalik/) for the inspiration and Docker hacks\n- [cookiecutter-django](https://github.com/cookiecutter/cookiecutter-django) for cookiecutter testing patterns\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickatnight%2Fcookiecutter-fastapi-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnickatnight%2Fcookiecutter-fastapi-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickatnight%2Fcookiecutter-fastapi-backend/lists"}