mirror of https://github.com/easzlab/kubeasz.git
fix ezdown
parent
82d4afaabc
commit
d194c03e0b
11
ezdown
11
ezdown
|
@ -13,9 +13,9 @@ set -o errexit
|
|||
#set -o xtrace
|
||||
|
||||
# default settings, can be overridden by cmd line options, see usage
|
||||
DOCKER_VER=20.10.9
|
||||
DOCKER_VER=20.10.16
|
||||
KUBEASZ_VER=3.2.0
|
||||
K8S_BIN_VER=v1.23.1
|
||||
K8S_BIN_VER=v1.24.1
|
||||
EXT_BIN_VER=1.0.0
|
||||
SYS_PKG_VER=0.4.2
|
||||
HARBOR_VER=v2.1.3
|
||||
|
@ -208,6 +208,7 @@ function get_kubeasz() {
|
|||
[[ -d "$BASE/roles/kube-node" ]] && { logger warn "kubeasz already existed"; return 0; }
|
||||
|
||||
logger info "downloading kubeasz: $KUBEASZ_VER"
|
||||
docker ps -a |grep -q temp_easz && { logger debug "remove existing container"; docker rm -f temp_easz; }
|
||||
logger debug " run a temporary container"
|
||||
docker run -d --name temp_easz easzlab/kubeasz:${KUBEASZ_VER} || { logger error "download failed."; exit 1; }
|
||||
|
||||
|
@ -230,6 +231,7 @@ function get_k8s_bin() {
|
|||
[[ -f "$BASE/bin/kubelet" ]] && { logger warn "kubernetes binaries existed"; return 0; }
|
||||
|
||||
logger info "downloading kubernetes: $K8S_BIN_VER binaries"
|
||||
docker ps -a |grep -q temp_k8s_bin && { logger debug "remove existing container"; docker rm -f temp_k8s_bin; }
|
||||
docker pull easzlab/kubeasz-k8s-bin:"$K8S_BIN_VER" && \
|
||||
logger debug "run a temporary container" && \
|
||||
docker run -d --name temp_k8s_bin easzlab/kubeasz-k8s-bin:${K8S_BIN_VER} && \
|
||||
|
@ -245,6 +247,7 @@ function get_ext_bin() {
|
|||
[[ -f "$BASE/bin/etcdctl" ]] && { logger warn "extra binaries existed"; return 0; }
|
||||
|
||||
logger info "downloading extral binaries kubeasz-ext-bin:$EXT_BIN_VER"
|
||||
docker ps -a |grep -q temp_ext_bin && { logger debug "remove existing container"; docker rm -f temp_ext_bin; }
|
||||
docker pull "easzlab/kubeasz-ext-bin:$EXT_BIN_VER" && \
|
||||
logger debug "run a temporary container" && \
|
||||
docker run -d --name temp_ext_bin "easzlab/kubeasz-ext-bin:$EXT_BIN_VER" && \
|
||||
|
@ -259,7 +262,7 @@ function get_ext_bin() {
|
|||
function get_sys_pkg() {
|
||||
[[ -f "$BASE/down/packages/chrony_xenial.tar.gz" ]] && { logger warn "system packages existed"; return 0; }
|
||||
|
||||
docker ps -a |grep temp_sys_pkg && { logger debug "remove existing container"; docker rm -f temp_sys_pkg; }
|
||||
docker ps -a |grep -q temp_sys_pkg && { logger debug "remove existing container"; docker rm -f temp_sys_pkg; }
|
||||
logger info "downloading system packages kubeasz-sys-pkg:$SYS_PKG_VER"
|
||||
docker pull "easzlab/kubeasz-sys-pkg:$SYS_PKG_VER" && \
|
||||
logger debug "run a temporary container" && \
|
||||
|
@ -273,7 +276,7 @@ function get_sys_pkg() {
|
|||
function get_harbor_offline_pkg() {
|
||||
[[ -f "$BASE/down/harbor-offline-installer-$HARBOR_VER.tgz" ]] && { logger warn "harbor-offline existed"; return 0; }
|
||||
|
||||
docker ps -a |grep temp_harbor && { logger debug "remove existing container"; docker rm -f temp_harbor; }
|
||||
docker ps -a |grep -q temp_harbor && { logger debug "remove existing container"; docker rm -f temp_harbor; }
|
||||
logger info "downloading harbor-offline:$HARBOR_VER"
|
||||
docker pull "easzlab/harbor-offline:$HARBOR_VER" && \
|
||||
logger debug "run a temporary container" && \
|
||||
|
|
Loading…
Reference in New Issue