Fss aims to be one of top scaffold in PyWeb.
Project description
特性
- 开箱即用, 内置常见数据库、缓存([默认]Sqlite, PostgreSQL, MySQL, [默认]文件缓存, Redis)
- 自带单表的几乎所有操作
- 数据库迁移, 静态代码扫描, 接口文档等一众特性
快速开始
- 首先确保python的版本是3.9及以上的
- 克隆代码
git clone https://github.com/tyvekzhang/fastapi-sqlmodel-starter
cd fastapi-sqlmodel-starter/src
- [可选]创建虚拟环境, 本篇以venv为例, 类似的工具还有conda, virtualenv等
python3 -m venv .env_fss
- [可选]激活虚拟环境
- Windows: .env_fss\Scripts\activate
- macOS 或 Linux: source .env_fss/bin/activate
- 安装 Poetry并下载依赖
pip install poetry --trusted-host=mirrors.tuna.tsinghua.edu.cn --index-url=https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple
poetry install
- 数据库迁移
alembic upgrade head
- 启动
- Windows: python3 fss\apiserver.py
- macOS 或 Linux: python3 fss/apiserver.py
- 访问: http://127.0.0.1:9010/docs
- 首先通过注册接口新建用户, 接着进行认证, 一切Ok.
文档
贡献
欢迎为 FastapiSqlmodelStarter 做出贡献!你可以通过以下方式参与:
- 提交 Bug 或功能需求到 Issue 追踪器
- 提交代码改进的 Pull Request
- 编写和改进文档
- 分享你使用 FastapiSqlmodelStarter 的经验和想法
许可证
FastapiSqlmodelStarter 采用 MIT 许可证开源。
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for fastapi_sqlmodel_starter-1.0.0b1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7a4016542bb3f15ef8b89792b9b452a60f566304277364999fa486fd082aeb01 |
|
MD5 | 8311d147b617dbd8a3d0379bd1dcd982 |
|
BLAKE2b-256 | 1587851758b00386cca5e181ba890fdb0eb7fd106b7b08c9e45921bbb7f59984 |
Close
Hashes for fastapi_sqlmodel_starter-1.0.0b1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b77087258d378aa1a00caa135b30613ef74041d7ef9bed132e7c48edba5f1b8f |
|
MD5 | dc3cca039b32ca6262740e8d1c2af0d6 |
|
BLAKE2b-256 | 56fb1f9ebe12d0c81c0da5a64a244c0318f6909ad9f99b4ffa29829ff9ef5880 |