Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ feat: 增加Docker支持 #19

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

✨ feat: 增加Docker支持 #19

wants to merge 8 commits into from

Conversation

zh3305
Copy link

@zh3305 zh3305 commented Sep 27, 2023

编译: build # docker build --pull --rm -f "Dockerfile" -t localcodeinterpreter:latest "."
运行:run # docker run --rm -it -e OPENAI_API_KEY= -p 7860:7860 localcodeinterpreter

@zh3305
Copy link
Author

zh3305 commented Sep 27, 2023

#14

@MrGreyfun
Copy link
Owner

MrGreyfun commented Sep 27, 2023

您好,感谢提交这个PR。一直以来,许多用户都希望为该项目添加Docker支持,但由于我对Docker不太熟悉,所以一直没有加入这个功能。因此,这对该项目来说是一次重要的改进。不过我认为还需要进行一些修改才能够合并这个PR。如果您愿意的话,请考虑以下建议:

  1. 增加一个专门用于Docker支持的web UI文件,例如命名为 web_ui_docker.py,而不是直接在现有的web_ui.py文件中将web服务的地址设置为 0.0.0.0。或者您可以添加一个命令行参数,例如 --docker,并使用Python的argparse模块来处理它。这样,通过运行 python web_ui.py --docker 命令来启动服务时才将地址设置为 0.0.0.0

  2. 请将Dockerfile中的注释改为英文,以确保代码库的一致性。

  3. git commit消息也请使用英文

  4. 最后,请在README文件中(包括中文和英文版本)添加有关如何使用Docker启动项目的详细说明。

@zh3305
Copy link
Author

zh3305 commented Sep 27, 2023

👌🏻

@zh3305 zh3305 force-pushed the main branch 2 times, most recently from 55c912f to 02fb09c Compare September 28, 2023 09:14
编译: build # docker build --pull --rm -f "Dockerfile" -t localcodeinterpreter:latest "."
运行:run # docker run   --rm -it  -e OPENAI_API_KEY=<youApikey> -p 7860:7860 localcodeinterpreter
@zh3305
Copy link
Author

zh3305 commented Sep 28, 2023

@MrGreyfun 已更新,docker的镜像我先通过github 发布到我自己的dockerhub上了,需要修改action 和在库中添加密钥,才能上传到你这边的库

@MrGreyfun
Copy link
Owner

@MrGreyfun 已更新,docker的镜像我先通过github 发布到我自己的dockerhub上了,需要修改action 和在库中添加密钥,才能上传到你这边的库

感谢更新,但我最近比较忙,等我有空了我会尽快审核你的PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants