Skip to content

Commit 711b886

Browse files
tmp
1 parent dcdf929 commit 711b886

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

components/common-go/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# How to upgrade Kubernetes dependencies
22

33
General steps:
4+
1. Check https://github.com/kubernetes/kubernetes/releases for the Kubernetes version. E.g. we use EKS 1.31, latest 1.31 Kubernetes release is 1.31.8 which is Kubernetes version 31.8. Run `./go-get-kubernetes.sh 31.8`.
45
1. modify target versions in `go-update-wc-deps.sh`
56
1. run `./go-update-wc-deps.sh`
67
1. if it fails, fix the test/code, and run it again until all tests are good - except `install/installer`

components/common-go/go-update-wc-deps.sh

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ WORKSPACE_CLUSTER_DEPENDENCIES["github.com/containerd/containerd"]="1.6.36"
1818
WORKSPACE_CLUSTER_DEPENDENCIES["github.com/moby/buildkit"]="0.12.5"
1919
WORKSPACE_CLUSTER_DEPENDENCIES["github.com/opencontainers/runc"]="1.1.14"
2020
# Reasoning for this version: https://pkg.go.dev/sigs.k8s.io/controller-runtime#section-readme
21-
WORKSPACE_CLUSTER_DEPENDENCIES["sigs.k8s.io/controller-runtime"]="0.18.7"
21+
WORKSPACE_CLUSTER_DEPENDENCIES["sigs.k8s.io/controller-runtime"]="0.19.7"
2222
# Prefix matches
23-
WORKSPACE_CLUSTER_DEPENDENCIES["k8s.io/"]="0.30.9"
23+
WORKSPACE_CLUSTER_DEPENDENCIES["k8s.io/"]="0.31.8"
2424

2525
# loop through keys of each associative array
2626
for key in "${!WORKSPACE_CLUSTER_DEPENDENCIES[@]}"
@@ -40,7 +40,7 @@ do
4040
# list all package to update, in case "key" is a prefix
4141
PACKAGES=$(grep -o "[[:space:]]${key}[^ ]*" go.mod | tr -d "[:blank:]" | sort | uniq)
4242
for p in ${PACKAGES}; do
43-
if [[ "$p" == k8s.io/klog* ]] || [[ "$p" == k8s.io/utils* ]] || [[ "$p" == k8s.io/kube-openapi* ]] || [[ "$p" == k8s.io/gengo* ]]; then
43+
if [[ "$p" == k8s.io/klog* ]] || [[ "$p" == k8s.io/utils* ]] || [[ "$p" == k8s.io/kube-openapi* ]] || [[ "$p" == k8s.io/gengo* ]] || [[ "$p" == k8s.io/legacy-cloud-providers* ]]; then
4444
# special case imported indirectly, we don't want to update these. Also, they have different versions.
4545
echo "Ignoring ${p}..."
4646
continue
@@ -51,6 +51,7 @@ do
5151
# shellcheck disable=SC2076
5252
if [[ ! " ${COMPONENTS_TO_TEST[*]} " =~ " ${FOLDER} " ]]; then
5353
COMPONENTS_TO_TEST+=("${FOLDER}")
54+
echo "${FOLDER}" >> /tmp/COMPONENTS_TO_TEST.txt
5455
fi
5556
fi
5657
done
@@ -69,15 +70,18 @@ INSTALLER_PACKAGE=""
6970

7071
for t in "${COMPONENTS_TO_TEST[@]}"
7172
do
72-
if [[ "${t}" == "*install/installer" ]]; then
73+
if [[ "${t}" == "install/installer" ]]; then
7374
# do after all others, as it's depending on all other packages
7475
INSTALLER_PACKAGE="${t}"
7576
continue
7677
fi
7778

7879
pushd "${t}"
80+
echo "+++++ $t"
7981
# clean it up
8082
go mod tidy
83+
leeway link .
84+
go mod tidy
8185
# assert that build and tests pass
8286

8387

@@ -91,6 +95,8 @@ done
9195

9296
if [[ -n "${INSTALLER_PACKAGE}" ]]; then
9397
pushd "${INSTALLER_PACKAGE}"
98+
99+
echo "+++++ INSTALLER"
94100
# clean it up
95101
go mod tidy
96102
# assert that build and tests pass

0 commit comments

Comments
 (0)