Skip to content

Repository files navigation

NettedX Backend

NettedX Backend is a backend service built with FastAPI, designed to provide a robust and efficient API for NettedX. This project is structured to facilitate easy development, testing, and deployment.

Technical Stack

  • FastAPI
  • Uvicorn
  • Pydantic Settings
  • Pytest + HTTPX
  • Ruff

Requirements

  • Python >= 3.12
  • uv

Development Guidelines

Please refer to the Development Guidelines

Running with Docker

For users and production environments.

Make sure you have Docker installed on your device.

There are two ways to run the application using Docker:

  1. With the source code:

Clone the repository and run the following command in the project root directory:

docker-compose up --build
  1. With released Docker image:

Pull the latest released Docker image from ghcr and run it:

docker run -p 8000:8000 ghcr.io/nettedx/nettedx-back:latest

Quick Start

For Developers.

  1. Clone the repository
git clone https://github.com/NettedX/nettedx-back.git
  1. Install dependencies
  uv sync
  1. Start the development server
  uv run dev

or

  uv run uvicorn app.main:app --reload
  1. Open the built-in documentation

Synchronized with your code in real-time, please refer to Apifox for the official documentation.

http://127.0.0.1:8000/docs

Available Commands

  • Run tests

      uv run pytest
  • Run linter

      uv run ruff check
  • Run formatter

    uv run ruff format

Environment Variables

All environment variables are managed using dotenv. Please refer to the .env.example file for a list of required environment variables.

Copy the .env.example file to .env and change the values as needed.

cp .env.example .env

About

NettedX Backend is a backend service built with FastAPI, designed to provide a robust and efficient API for NettedX.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages