Skip to content

Commit

Permalink
K8SPXC-1295 - Fix default-cr test and OPERATOR_VERSION in functions (#…
Browse files Browse the repository at this point in the history
…1482)

* K8SPXC-1295 - Fix default-cr test and OPERATOR_VERSION in functions

* Advance GKE version in Jenkinsfile to 1.24

* Fix monitoring-2-0 test
  • Loading branch information
tplavcic authored Sep 21, 2023
1 parent 3c69063 commit 1a4defa
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ void createCluster(String CLUSTER_SUFFIX) {
gcloud config set project $GCP_PROJECT
gcloud container clusters list --filter $CLUSTER_NAME-${CLUSTER_SUFFIX} --zone $GKERegion --format='csv[no-heading](name)' | xargs gcloud container clusters delete --zone $GKERegion --quiet || true
gcloud container clusters create --zone $GKERegion $CLUSTER_NAME-${CLUSTER_SUFFIX} --cluster-version=1.23 --machine-type=n1-standard-4 --preemptible --disk-size 30 --num-nodes=\$NODES_NUM --network=jenkins-vpc --subnetwork=jenkins-${CLUSTER_SUFFIX} --no-enable-autoupgrade --cluster-ipv4-cidr=/21 --labels delete-cluster-after-hours=6 && \
gcloud container clusters create --zone $GKERegion $CLUSTER_NAME-${CLUSTER_SUFFIX} --cluster-version=1.24 --machine-type=n1-standard-4 --preemptible --disk-size 30 --num-nodes=\$NODES_NUM --network=jenkins-vpc --subnetwork=jenkins-${CLUSTER_SUFFIX} --no-enable-autoupgrade --cluster-ipv4-cidr=/21 --labels delete-cluster-after-hours=6 && \
kubectl create clusterrolebinding cluster-admin-binding --clusterrole cluster-admin --user jenkins@"$GCP_PROJECT".iam.gserviceaccount.com || ret_val=\$?
if [ \${ret_val} -eq 0 ]; then break; fi
ret_num=\$((ret_num + 1))
Expand Down
2 changes: 1 addition & 1 deletion e2e-tests/default-cr/run
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function stop_cluster() {
until [[ $(kubectl_bin get pxc ${cluster_name} -o jsonpath='{.status.ready}') -le 0 ]]; do
echo -n .
let passed_time="${passed_time}+${sleep_time}"
sleep ${passed_time}
sleep ${sleep_time}
if [[ ${passed_time} -gt ${max_wait_time} ]]; then
echo "We've been waiting for cluster stop for too long. Exiting..."
exit 1
Expand Down
2 changes: 1 addition & 1 deletion e2e-tests/functions
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ GIT_COMMIT=$(git rev-parse HEAD)
BUILD_TIME=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
GIT_BRANCH=${VERSION:-$(git rev-parse --abbrev-ref HEAD | sed -e 's^/^-^g; s^[.]^-^g;' | tr '[:upper:]' '[:lower:]')}
API="pxc.percona.com/v1"
OPERATOR_VERSION="1.13.0"
OPERATOR_VERSION="$(grep 'crVersion' $(realpath $(dirname ${BASH_SOURCE[0]})/../deploy/cr.yaml) | awk '{print $2}')"
IMAGE=${IMAGE:-"perconalab/percona-xtradb-cluster-operator:${GIT_BRANCH}"}
MYSQL_VERSION=${MYSQL_VERSION:-"8.0"}
IMAGE_PXC=${IMAGE_PXC:-"perconalab/percona-xtradb-cluster-operator:main-pxc${MYSQL_VERSION}"}
Expand Down
1 change: 1 addition & 0 deletions e2e-tests/monitoring-2-0/compare/agents-list.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@
"service_type": "postgresql",
"database_name": "postgres",
"node_name": "pmm-server",
"cluster": "pmm-server-postgresql",
"address": "127.0.0.1",
"port": 5432,
"agents": [
Expand Down

0 comments on commit 1a4defa

Please sign in to comment.