From acec1e2d7bb5f93143311d96440285ab3ac7de73 Mon Sep 17 00:00:00 2001 From: Andrey Velichkevich Date: Mon, 22 Mar 2021 02:10:17 +0000 Subject: [PATCH] Fix release script to replace Katib image tags (#1493) * Fix release script to replace Katib image tags * Increase restart timeout in e2e --- scripts/v1beta1/release.sh | 14 ++++++++++---- test/e2e/v1beta1/run-e2e-experiment.go | 2 +- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/scripts/v1beta1/release.sh b/scripts/v1beta1/release.sh index 19b86c2c64d..cd49e4f6ad5 100755 --- a/scripts/v1beta1/release.sh +++ b/scripts/v1beta1/release.sh @@ -70,9 +70,15 @@ fi echo -e "\nUpdating Katib image tags to ${TAG}\n" # For MacOS we should set -i '' to avoid temp files from sed. if [[ $(uname) == "Darwin" ]]; then - find ./manifests/v1beta1/installs -regex ".*\.yaml" -exec sed -i '' -e "s@newTag: .*@newTag: ${TAG}@" {} \; + sed -i '' -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-external-db/kustomization.yaml + sed -i '' -e "s@:[^[:space:]].*\"@:${TAG}\"@" ./manifests/v1beta1/installs/katib-standalone/katib-config-patch.yaml + sed -i '' -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-standalone/kustomization.yaml + sed -i '' -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-with-kubeflow/kustomization.yaml else - find ./manifests/v1beta1/installs -regex ".*\.yaml" -exec sed -i -e "s@newTag: .*@newTag: ${TAG}@" {} \; + sed -i -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-external-db/kustomization.yaml + sed -i -e "s@:[^[:space:]].*\"@:${TAG}\"@" ./manifests/v1beta1/installs/katib-standalone/katib-config-patch.yaml + sed -i -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-standalone/kustomization.yaml + sed -i -e "s@newTag: .*@newTag: ${TAG}@" ./manifests/v1beta1/installs/katib-with-kubeflow/kustomization.yaml fi echo -e "Katib images have been updated\n" @@ -95,7 +101,7 @@ python3 setup.py sdist bdist_wheel twine upload dist/* rm -r dist/ build/ cd ../../.. -echo -e "Katib Python SDK ${SDK_VERSION} has been published\n" +echo -e "\nKatib Python SDK ${sdk_version} has been published\n" # ------------------ Commit changes ------------------ git commit -a -m "Katib official release ${TAG}" @@ -104,7 +110,7 @@ git tag ${TAG} # ------------------ Publish Katib images ------------------ # Publish images to the registry with 2 tags: ${TAG} and v1beta1- -echo -e "Publishing Katib images\n" +echo -e "\nPublishing Katib images\n" make push-tag TAG=${TAG} echo -e "Katib images have been published\n" diff --git a/test/e2e/v1beta1/run-e2e-experiment.go b/test/e2e/v1beta1/run-e2e-experiment.go index 289a9664590..b85267cf585 100644 --- a/test/e2e/v1beta1/run-e2e-experiment.go +++ b/test/e2e/v1beta1/run-e2e-experiment.go @@ -128,7 +128,7 @@ func main() { exp.Name, maxTrials, parallelTrials) // Wait until Experiment is restarted. - timeout := 10 * time.Second + timeout := 60 * time.Second endTime := time.Now().Add(timeout) for time.Now().Before(endTime) { exp, err = kclient.GetExperiment(exp.Name, exp.Namespace)