From 9cc8ecd01ad551ce1b6a468dbfdce7280dadcebf Mon Sep 17 00:00:00 2001 From: deng Date: Mon, 25 May 2026 13:58:29 +0800 Subject: [PATCH] extract streamlit config --- Dockerfile | 2 +- translator/.streamlit/config.toml | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 translator/.streamlit/config.toml diff --git a/Dockerfile b/Dockerfile index 200fd4e..14b1b59 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,7 +18,7 @@ COPY --from=builder /usr/local/lib/python3.13/site-packages /usr/local/lib/pytho WORKDIR /app COPY ./translator . EXPOSE 8501 -CMD ["python", "-m", "streamlit", "run", "app.py", "--server.port=8501", "--server.enableCORS=false", "--server.enableXsrfProtection=false"] +CMD ["python", "-m", "streamlit", "run", "app.py"] # Build # docker build --platform=linux/amd64 -t translator:latest . diff --git a/translator/.streamlit/config.toml b/translator/.streamlit/config.toml new file mode 100644 index 0000000..e63a579 --- /dev/null +++ b/translator/.streamlit/config.toml @@ -0,0 +1,10 @@ +[theme] +base = "dark" + +[server] +port = 8501 +enableCORS = false +enableXsrfProtection = false + +[client] +toolbarMode = "minimal" \ No newline at end of file