Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
tingweiwang
/
k8s
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 493f16de
authored
Apr 13, 2020
by
tingweiwang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kubelet去掉allow privilege,修改推送镜像仓库位置
1 parent
32bd1081
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
14 deletions
script/k8s/add_node.sh
script/k8s/deploy-gpu-k8s.sh
script/k8s/add_node.sh
View file @
493f16d
...
...
@@ -95,7 +95,6 @@ KUBELET_OPTS="--logtostderr=false \
--bootstrap-kubeconfig=/opt/kubernetes/cfg/bootstrap.kubeconfig \
--config=/opt/kubernetes/cfg/kubelet.config \
--cert-dir=/opt/kubernetes/ssl \
--allow-privileged=true \
--pod-infra-container-image=$harbor_host/k8s/pause-amd64:3.0"
EOF
scp /opt/kubernetes/cfg/kubelet.
$new_node_ip
$new_node_ip
:/opt/kubernetes/cfg/kubelet
...
...
script/k8s/deploy-gpu-k8s.sh
View file @
493f16d
...
...
@@ -328,7 +328,6 @@ KUBELET_OPTS="--logtostderr=false \
--bootstrap-kubeconfig=/opt/kubernetes/cfg/bootstrap.kubeconfig \
--config=/opt/kubernetes/cfg/kubelet.config \
--cert-dir=/opt/kubernetes/ssl \
--allow-privileged=true \
--pod-infra-container-image=$harbor_host/k8s/pause-amd64:3.0"
EOF
scp /opt/kubernetes/cfg/kubelet.
$node_ip
$node_ip
:/opt/kubernetes/cfg/kubelet
...
...
@@ -400,23 +399,21 @@ echo "开始导入镜像到本地"
docker load -i
$image_path
/
$image
done
echo
"开始给镜像打tag"
docker tag autodl/image-proxy:v0.9.0
$harbor_host
/k8s/image-proxy:v0.9.0
docker tag autodl/ubuntu-basic:16.04
$harbor_host
/k8s/ubuntu-basic:16.04
docker tag coredns/coredns:1.5.0
$harbor_host
/k8s/coredns:1.5.0
docker tag nvidia/k8s-device-plugin:1.10
$harbor_host
/k8s/k8s-device-plugin:1.10
docker tag busybox:1.28.3
$harbor_host
/k8s/busybox:1.28.3
docker tag registry.cn-hangzhou.aliyuncs.com/google-containers/pause-amd64:3.0
$harbor_host
/k8s/pause-amd64:3.0
docker tag nginx:latest
$harbor_host
/k8s/nginx:latest
docker tag nvidia/cuda:10.0-base-ubuntu16.04
$harbor_host
/k8s/cuda:10.0-base-ubuntu16.04
docker tag hub.kce.ksyun.com/kpl_k8s/image-proxy:v0.9.2
$harbor_host
/k8s/image-proxy:v0.9.2
docker tag hub.kce.ksyun.com/kpl_k8s/ubuntu-basic:16.04
$harbor_host
/k8s/ubuntu-basic:16.04
docker tag hub.kce.ksyun.com/kpl_k8s/coredns:1.5.0
$harbor_host
/k8s/coredns:1.5.0
docker tag hub.kce.ksyun.com/kpl_k8s/k8s-device-plugin:1.0.0-beta4
$harbor_host
/k8s/k8s-device-plugin:1.0.0-beta4
docker tag hub.kce.ksyun.com/kpl_k8s/pause-amd64:3.0
$harbor_host
/k8s/pause-amd64:3.0
docker tag hub.kce.ksyun.com/kpl_k8s/nginx:latest
$harbor_host
/k8s/nginx:latest
docker tag hub.kce.ksyun.com/kpl_k8s/cuda:10.0-base-ubuntu16.04
$harbor_host
/k8s/cuda:10.0-base-ubuntu16.04
echo
"开始推送镜像到harbor"
echo
"您的harbor服务器访问地址为:
$harbor_host
,请创建harbor所项目目录:k8s core autodl seetaas autodl-workspac
e
m 您有90s的时间"
echo
"您的harbor服务器访问地址为:
$harbor_host
,请创建harbor所项目目录:k8s core autodl seetaas autodl-workspacm 您有90s的时间"
sleep 90
docker login
$harbor_host
-uadmin -p
$harbor_passwd
docker push
$harbor_host
/k8s/image-proxy:v0.9.
0
docker push
$harbor_host
/k8s/image-proxy:v0.9.
2
docker push
$harbor_host
/k8s/ubuntu-basic:16.04
docker push
$harbor_host
/k8s/coredns:1.5.0
docker push
$harbor_host
/k8s/k8s-device-plugin:1.10
docker push
$harbor_host
/k8s/busybox:1.28.3
docker push
$harbor_host
/k8s/k8s-device-plugin:1.0.0-beta4
docker push
$harbor_host
/k8s/pause-amd64:3.0
docker push
$harbor_host
/k8s/nginx:latest
docker push
$harbor_host
/k8s/cuda:10.0-base-ubuntu16.04
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment