Skip to content

Commit

Permalink
Download fixed version of eksctl to avoid bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
wongma7 committed Jul 6, 2021
1 parent 3b2f497 commit e0938d0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion hack/e2e/eksctl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ set -euo pipefail

function eksctl_install() {
INSTALL_PATH=${1}
EKSCTL_VERSION=${2}
if [[ ! -e ${INSTALL_PATH}/eksctl ]]; then
EKSCTL_DOWNLOAD_URL="https://github.com/weaveworks/eksctl/releases/latest/download/eksctl_$(uname -s)_amd64.tar.gz"
EKSCTL_DOWNLOAD_URL="https://github.com/weaveworks/eksctl/releases/download/${EKSCTL_VERSION}/eksctl_$(uname -s)_amd64.tar.gz"
curl --silent --location "${EKSCTL_DOWNLOAD_URL}" | tar xz -C "${INSTALL_PATH}"
chmod +x "${INSTALL_PATH}"/eksctl
fi
Expand Down
5 changes: 3 additions & 2 deletions hack/e2e/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ KOPS_STATE_FILE=${KOPS_STATE_FILE:-s3://k8s-kops-csi-e2e}
KOPS_PATCH_FILE=${KOPS_PATCH_FILE:-./hack/kops-patch.yaml}
KOPS_PATCH_NODE_FILE=${KOPS_PATCH_NODE_FILE:-./hack/kops-patch-node.yaml}

EKSCTL_VERSION=${EKSCTL_VERSION:-0.56.0-rc.1}
EKSCTL_PATCH_FILE=${EKSCTL_PATCH_FILE:-./hack/eksctl-patch.yaml}
EKSCTL_ADMIN_ROLE=${EKSCTL_ADMIN_ROLE:-}

Expand Down Expand Up @@ -84,8 +85,8 @@ if [[ "${CLUSTER_TYPE}" == "kops" ]]; then
kops_install "${BIN_DIR}" "${KOPS_VERSION}"
KOPS_BIN=${BIN_DIR}/kops
elif [[ "${CLUSTER_TYPE}" == "eksctl" ]]; then
loudecho "Installing eksctl latest to ${BIN_DIR}"
eksctl_install "${BIN_DIR}"
loudecho "Installing eksctl ${EKSCTL_VERSION} to ${BIN_DIR}"
eksctl_install "${BIN_DIR}" "${EKSCTL_VERSION}"
EKSCTL_BIN=${BIN_DIR}/eksctl
else
loudecho "${CLUSTER_TYPE} must be kops or eksctl!"
Expand Down

0 comments on commit e0938d0

Please sign in to comment.