From 3cb1b169e713e8602f59dd5273340f0aba8c4784 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=87=8C=E6=96=87=E9=BE=99?= Date: Wed, 22 Jun 2022 09:10:21 +0000 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20'Dockerfile'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Dockerfile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..4379716 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,22 @@ +FROM docker:20.10.17-dind + +RUN sed -i "s@https://dl-cdn.alpinelinux.org/@https://mirrors.huaweicloud.com/@g" /etc/apk/repositories; \ + mkdir -p /etc/docker; \ + echo $'{ \n\ + "registry-mirrors": [ \n\ + "https://ktrsh7na.mirror.aliyuncs.com" \n\ + ] \n\ +}' >> /etc/docker/daemon.json; \ + mkdir -p /root/.docker; \ + echo $'{ \n\ + "auths": { \n\ + "repository.anxinyun.cn": { \n\ + "auth": "YWRtaW46SGFyYm9yMTIzNDU=" \n\ + }, \n\ + "registry.cn-hangzhou.aliyuncs.com": { \n\ + "auth": "==auth==" \n\ + } \n\ + } \n\ +}' >> /root/.docker/config.json.temp + +COPY switch-auth.sh /usr/local/bin/