Rename project for AdCloud tracking and ad delivery

This commit is contained in:
2026-09-15 19:04:53 +08:00
parent fd30c83152
commit f418e92673
6 changed files with 12 additions and 10 deletions
+6 -4
View File
@@ -1,12 +1,14 @@
# Python 后端服务器
# AdCloud Server
使用 FastAPI 开发,依赖和虚拟环境统一由 **uv** 管理。
面向开发者和 coding agent 的广告云埋点与广告推送后端。使用 FastAPI 开发,依赖和虚拟环境统一由 **uv** 管理。
当前为开发脚手架,提供健康检查与 API 文档;埋点与广告推送功能待实现。
## 开发
```sh
uv sync
uv run uvicorn backend_server.main:app --reload --host 127.0.0.1 --port 8000
uv run uvicorn adcloud_server.main:app --reload --host 127.0.0.1 --port 8000
```
- 健康检查:`http://localhost:8000/health`
@@ -17,7 +19,7 @@ uv run uvicorn backend_server.main:app --reload --host 127.0.0.1 --port 8000
通过环境变量配置逗号分隔的允许来源:
```sh
CORS_ORIGINS=https://your-frontend.example uv run uvicorn backend_server.main:app
CORS_ORIGINS=https://your-frontend.example uv run uvicorn adcloud_server.main:app
```
## 检查
+3 -3
View File
@@ -1,7 +1,7 @@
[project]
name = "entroia-backend-server"
name = "adcloud-server"
version = "0.1.0"
description = "Python backend for the Entroia React SDK"
description = "AdCloud tracking and ad delivery backend for developers and coding agents"
readme = "README.md"
requires-python = ">=3.12"
dependencies = ["fastapi>=0.115,<1", "uvicorn>=0.30,<1"]
@@ -14,7 +14,7 @@ requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["src/backend_server"]
packages = ["src/adcloud_server"]
[tool.pytest.ini_options]
testpaths = ["tests"]
@@ -5,7 +5,7 @@ from fastapi import FastAPI
from fastapi.middleware.cors import CORSMiddleware
from pydantic import BaseModel
app = FastAPI(title="Entroia Backend", version="0.1.0")
app = FastAPI(title="AdCloud Server", version="0.1.0")
app.add_middleware(
CORSMiddleware,
allow_origins=[
+1 -1
View File
@@ -1,6 +1,6 @@
from fastapi.testclient import TestClient
from backend_server.main import app
from adcloud_server.main import app
client = TestClient(app)
Generated
+1 -1
View File
@@ -61,7 +61,7 @@ wheels = [
]
[[package]]
name = "entroia-backend-server"
name = "adcloud-server"
version = "0.1.0"
source = { editable = "." }
dependencies = [