From db4243d67d282bb4578d5e81342d736433f64af1 Mon Sep 17 00:00:00 2001 From: hailin Date: Tue, 8 Jul 2025 19:16:17 +0800 Subject: [PATCH] . --- Dockerfile | 2 +- build-and-run.sh | 2 +- gradio_ui.py | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9be8008..f895894 100644 --- a/Dockerfile +++ b/Dockerfile @@ -51,7 +51,7 @@ COPY --from=builder /install /usr/local COPY --from=builder /build/gradio_ui.py /app/gradio_ui.py WORKDIR /app -EXPOSE 7900 +EXPOSE 7900 7901 # 可选:彻底关闭 pip 缓存,避免 runtime 再次安装时产生垃圾 ENV PIP_NO_CACHE_DIR=1 diff --git a/build-and-run.sh b/build-and-run.sh index 7837ad5..eb85699 100644 --- a/build-and-run.sh +++ b/build-and-run.sh @@ -37,5 +37,5 @@ docker build -t "$IMAGE_NAME" . # ======== 5. 运行容器 ======== echo "🚀 启动容器:$CONTAINER_NAME" -docker run --rm -p 7900:7900 --name "$CONTAINER_NAME" "$IMAGE_NAME" +docker run --rm -p 7900:7900 -p 7901:7901--name "$CONTAINER_NAME" "$IMAGE_NAME" diff --git a/gradio_ui.py b/gradio_ui.py index e95b1cf..4489e15 100644 --- a/gradio_ui.py +++ b/gradio_ui.py @@ -67,7 +67,7 @@ def run_eval( full_output += "[Eval Finished]\n" if "Evaluation Report" in output_choices: - vis_port = 7861 + vis_port = 7901 outputs_root = "./outputs" try: latest_output = max( @@ -193,7 +193,7 @@ with gr.Blocks(title="EvalScope 全功能界面") as demo: with gr.Column(visible=False) as api_fields: api_url_input = gr.Textbox( label="API 地址", - placeholder="https://api.example.com/v1/chat" + placeholder="https://ai.aiszaiai.com/v1/chat/completions" ) api_token_input = gr.Textbox( label="Token 密钥",