- RESTful API Server Sample code based on Python FastAPI
- Database such as Sqlite is accessed such as insert, select, update and delete (CRUD) via SQLAlchemy JPA
LockModeType.PESSIMISTIC_WRITE 를 이용한 데이터 동시성 제어- Container creation and execution using Docker
- Execution file creation by Pyinstaller
- Writing test code in order to execute by Pytest
- Applying Basic Authentication and OAuth Token
- Added Ollama’s Rest API client integration function
- Python 3.12
- FastAPI
- Uvicorn
- Pydantic
- SQLAlchemy
- SQLite
- Docker
- Swagger UI
- pytest
- uvicorn train.app.application:app --host 0.0.0.0 --port 9084
- python train\app\application.py
- set PYTHONPATH=%PYTHONPATH%;%cd%
- pip freeze > requirements.txt
- pyinstaller main.spec
- docker build -t pyserver:local . && docker run --gpus=all -p 9084:9083 pyserver:local --port 9083
- docker-compse up
- pytest test\controller
- Swagger UI : http://localhost:9084/docs