From 16154bb5ae64892a7b0a2bdcbef38a0309ab79e5 Mon Sep 17 00:00:00 2001 From: Mison Date: Mon, 23 Mar 2026 11:59:24 +0800 Subject: [PATCH] fix: change default port to 15555 --- Dockerfile | 4 ++-- README.md | 6 +++--- docker-compose.yml | 6 +++--- src/config/constants.py | 2 +- src/config/settings.py | 4 ++-- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index db63397..35f9cbb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,7 @@ ENV PYTHONDONTWRITEBYTECODE=1 \ PYTHONUNBUFFERED=1 \ # WebUI 默认配置 WEBUI_HOST=0.0.0.0 \ - WEBUI_PORT=1455 \ + WEBUI_PORT=15555 \ LOG_LEVEL=info \ DEBUG=0 @@ -30,7 +30,7 @@ RUN pip install --no-cache-dir --upgrade pip \ COPY . . # 暴露端口 -EXPOSE 1455 +EXPOSE 15555 # 启动 WebUI CMD ["python", "webui.py"] diff --git a/README.md b/README.md index f62cf10..e8a30ef 100644 --- a/README.md +++ b/README.md @@ -144,9 +144,9 @@ docker-compose up -d ```bash docker run -d \ - -p 1455:1455 \ + -p 15555:15555 \ -e WEBUI_HOST=0.0.0.0 \ - -e WEBUI_PORT=1455 \ + -e WEBUI_PORT=15555 \ -e WEBUI_ACCESS_PASSWORD=your_secure_password \ -v $(pwd)/data:/app/data \ --name codex-register \ @@ -155,7 +155,7 @@ docker run -d \ 环境变量说明: - `WEBUI_HOST`: 监听的主机地址 (默认 `0.0.0.0`) -- `WEBUI_PORT`: 监听的端口 (默认 `1455`) +- `WEBUI_PORT`: 监听的端口 (默认 `15555`) - `WEBUI_ACCESS_PASSWORD`: 设置 Web UI 的访问密码 - `DEBUG`: 设为 `1` 或 `true` 开启调试模式 - `LOG_LEVEL`: 日志级别,如 `info`, `debug` diff --git a/docker-compose.yml b/docker-compose.yml index bd2b5e9..433d29c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -4,10 +4,10 @@ services: webui: build: . ports: - - "1455:1455" + - "15555:15555" environment: - WEBUI_HOST=0.0.0.0 - - WEBUI_PORT=1455 + - WEBUI_PORT=15555 - DEBUG=0 - LOG_LEVEL=info # 如果需要访问密码,可以在这里取消注释并设置 @@ -16,4 +16,4 @@ services: # 挂载数据目录以持久化数据库和日志 - ./data:/app/data - ./logs:/app/logs - restart: unless-stopped \ No newline at end of file + restart: unless-stopped diff --git a/src/config/constants.py b/src/config/constants.py index 1469c18..1ba4d0e 100644 --- a/src/config/constants.py +++ b/src/config/constants.py @@ -56,7 +56,7 @@ APP_DESCRIPTION = "自动注册 OpenAI/Codex CLI 账号的系统" OAUTH_CLIENT_ID = "app_EMoamEEZ73f0CkXaXp7hrann" OAUTH_AUTH_URL = "https://auth.openai.com/oauth/authorize" OAUTH_TOKEN_URL = "https://auth.openai.com/oauth/token" -OAUTH_REDIRECT_URI = "http://localhost:1455/auth/callback" +OAUTH_REDIRECT_URI = "http://localhost:15555/auth/callback" OAUTH_SCOPE = "openid email profile offline_access" # OpenAI API 端点 diff --git a/src/config/settings.py b/src/config/settings.py index aac2b97..974c9c4 100644 --- a/src/config/settings.py +++ b/src/config/settings.py @@ -136,7 +136,7 @@ SETTING_DEFINITIONS: Dict[str, SettingDefinition] = { ), "openai_redirect_uri": SettingDefinition( db_key="openai.redirect_uri", - default_value="http://localhost:1455/auth/callback", + default_value="http://localhost:15555/auth/callback", category=SettingCategory.OPENAI, description="OpenAI OAuth 回调 URI" ), @@ -622,7 +622,7 @@ class Settings(BaseModel): openai_client_id: str = "app_EMoamEEZ73f0CkXaXp7hrann" openai_auth_url: str = "https://auth.openai.com/oauth/authorize" openai_token_url: str = "https://auth.openai.com/oauth/token" - openai_redirect_uri: str = "http://localhost:1455/auth/callback" + openai_redirect_uri: str = "http://localhost:15555/auth/callback" openai_scope: str = "openid email profile offline_access" # 代理配置