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

Go项目多阶段构建Docker镜像 | 李斌的技术博客 #264

Open
jefferyjob opened this issue Oct 9, 2024 · 0 comments
Open

Go项目多阶段构建Docker镜像 | 李斌的技术博客 #264

jefferyjob opened this issue Oct 9, 2024 · 0 comments

Comments

@jefferyjob
Copy link
Member

https://blog.mailjob.net/posts/1304110700.html

在 Docker 17.05 版本之前,我们构建 Docker 镜像时,通常会采用两种方式: 全部放入一个 Dockerfile 一种方式是将所有的构建过程编包含在一个 Dockerfile 中,包括项目及其依赖库的编译、测试、打包等流程,这里可能会带来的一些问题: 镜像层次多,镜像体积较大,部署时间变长 源代码存在泄露的风险 例如,编写 app.go 文件,该程序输出 Hello World

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

No branches or pull requests

1 participant