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

海外机器构建docker镜像是目前最迫切的问题! #10

Open
zeusro opened this issue Feb 21, 2020 · 5 comments
Open

海外机器构建docker镜像是目前最迫切的问题! #10

zeusro opened this issue Feb 21, 2020 · 5 comments
Assignees

Comments

@zeusro
Copy link

zeusro commented Feb 21, 2020

被dockerfile apt-get update -y 支配的恐惧

相关建议:
容器镜像服务支持私有仓库海外机器构建

@zeusro zeusro changed the title 海外机器构建docker是目前最迫切的问题! 海外机器构建docker镜像是目前最迫切的问题! Feb 21, 2020
@denverdino
Copy link

可以参考一下 https://github.com/AliyunContainerService/ubuntu-image/blob/master/16.04/Dockerfile

使用阿里云mirror来构建

@zeusro
Copy link
Author

zeusro commented Feb 21, 2020

可以参考一下 https://github.com/AliyunContainerService/ubuntu-image/blob/master/16.04/Dockerfile

使用阿里云mirror来构建

apt 只是一个例子,还有yum ,apk ,php ,maven,gradle 等等一系列需要网络环境安装的工具。

如果是alpine 类系统,还得特意去适配系统,比如

FROM alpine:3.8
RUN export version=$(cat /etc/alpine-release) && \
    echo https://mirrors.ustc.edu.cn/alpine/v${version%.*}/main > /etc/apk/repositories && \
    echo https://mirrors.ustc.edu.cn/alpine/v${version%.*}/community >> /etc/apk/repositories;\
    echo "Asia/Shanghai" > /etc/timezone ;\

觉得如果啥工具链都要先考虑加上代理,这已经严重背离了docker ”节约开发时间,提高开发效率“的初衷。
虽然说 baseimage 可以解决大部分问题,但镜像本身是需要不断更新构建的。

@zeusro
Copy link
Author

zeusro commented Feb 21, 2020

同步 base image 本身也需要一个不停拉取同步的工作量。

@denverdino
Copy link

阿里云镜像服务 https://www.aliyun.com/product/acr 提供了海外镜像构建 可以参考 https://help.aliyun.com/document_detail/60997.html

@zeusro
Copy link
Author

zeusro commented Feb 21, 2020

阿里云镜像服务 https://www.aliyun.com/product/acr 提供了海外镜像构建 可以参考 https://help.aliyun.com/document_detail/60997.html

我用过你们的海外镜像构建,但是功能有局限性,对私有项目支持不够,我在聆听那边也说了:

  1. 支持 gogs,gitea ;
  2. 开放镜像构建的SDK,让用户可以通过在国内调用镜像服务的接口实现定制化海外镜像构建,按流量付费。

我知道你是想说,通过多个 git push URL 推送到私有云code,但是,如无必要,勿增实体

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

3 participants