Log: /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/logs/security-context-8-0.log Warning: version difference between client (1.34) and server (1.31) exceeds the supported minor version skew of +/-1 Warning: version difference between client (1.34) and server (1.31) exceeds the supported minor version skew of +/-1 + create_infra security-context-29660 + local ns=security-context-29660 + '[' -n pxc-operator ']' + grep -v NAMESPACE + xargs -L 1 sh -xc 'kubectl patch pxc -n $0 $1 --type=merge -p "{\"metadata\":{\"finalizers\":[]}}"' + kubectl get pxc --all-namespaces -o wide + kubectl patch pxc -n security-context-7073 sec-context --type=merge -p '{"metadata":{"finalizers":[]}}' perconaxtradbcluster.pxc.percona.com/sec-context patched + kubectl_bin delete pxc --all --all-namespaces ++ mktemp + local LAST_OUT=/tmp/tmp.OyRrqBN6Jl ++ mktemp + local LAST_ERR=/tmp/tmp.fvliCIfFMC + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl delete pxc --all --all-namespaces + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.OyRrqBN6Jl perconaxtradbcluster.pxc.percona.com "sec-context" deleted from security-context-7073 namespace + cat /tmp/tmp.fvliCIfFMC + rm /tmp/tmp.OyRrqBN6Jl /tmp/tmp.fvliCIfFMC + return 0 + kubectl_bin delete pxc-backup --all --all-namespaces ++ mktemp + local LAST_OUT=/tmp/tmp.M5lr9Y26i2 ++ mktemp + local LAST_ERR=/tmp/tmp.7Mq46CACL5 + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl delete pxc-backup --all --all-namespaces + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.M5lr9Y26i2 No resources found + cat /tmp/tmp.7Mq46CACL5 + rm /tmp/tmp.M5lr9Y26i2 /tmp/tmp.7Mq46CACL5 + return 0 + kubectl_bin delete pxc-restore --all --all-namespaces ++ mktemp + local LAST_OUT=/tmp/tmp.0mO9xcYITG ++ mktemp + local LAST_ERR=/tmp/tmp.fypJkIVgFG + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl delete pxc-restore --all --all-namespaces + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.0mO9xcYITG No resources found + cat /tmp/tmp.fypJkIVgFG + rm /tmp/tmp.0mO9xcYITG /tmp/tmp.fypJkIVgFG + return 0 + create_namespace pxc-operator + local namespace=pxc-operator + local skip_clean_namespace= + [[ 1 == 1 ]] + [[ -z '' ]] + destroy_chaos_mesh ++ helm list --all-namespaces --filter chaos-mesh ++ sed s/NAMESPACE// ++ tail -n1 ++ awk '-F ' '{print $2}' + local chaos_mesh_ns= + '[' -n '' ']' ++ kubectl get MutatingWebhookConfiguration ++ awk '{print $1}' ++ grep chaos-mesh + timeout 30 kubectl delete MutatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep validate-auth ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl api-resources ++ grep chaos-mesh ++ awk '{print $1}' ++ awk '{print $1}' ++ kubectl get crd ++ grep chaos-mesh.org + timeout 30 kubectl delete crd error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrolebinding ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrolebinding error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrole ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrole error: resource(s) were provided, but no name was specified + : + desc 'cleaned up all old namespaces' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up all old namespaces ----------------------------------------------------------------------------------- + '[' -n '' ']' + desc 'cleaned up old namespaces pxc-operator' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up old namespaces pxc-operator ----------------------------------------------------------------------------------- + kubectl_bin delete namespace pxc-operator ++ mktemp + egrep -v '^kube-|^default|Terminating|pxc-operator|openshift|^gke-|^gmp-|^NAME' + kubectl_bin get ns ++ mktemp + xargs kubectl delete ns + local LAST_OUT=/tmp/tmp.CIa61EJupn + local LAST_OUT=/tmp/tmp.3M0rkJkxkd ++ mktemp + local LAST_ERR=/tmp/tmp.95rQRPW7v9 + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl get ns + awk '{print$1}' ++ mktemp + local LAST_ERR=/tmp/tmp.TCxeftLZ43 + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl delete namespace pxc-operator + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.3M0rkJkxkd + cat /tmp/tmp.95rQRPW7v9 + rm /tmp/tmp.3M0rkJkxkd /tmp/tmp.95rQRPW7v9 + return 0 namespace "cert-manager" deleted namespace "security-context-7073" deleted + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.CIa61EJupn namespace "pxc-operator" deleted + cat /tmp/tmp.TCxeftLZ43 + rm /tmp/tmp.CIa61EJupn /tmp/tmp.TCxeftLZ43 + return 0 + wait_for_delete namespace/pxc-operator + local res=namespace/pxc-operator + echo -n 'waiting for namespace/pxc-operator to be deleted' waiting for namespace/pxc-operator to be deleted+ set +o xtrace Error from server (NotFound): namespaces "pxc-operator" not found + desc 'create namespace pxc-operator' + set +o xtrace ----------------------------------------------------------------------------------- create namespace pxc-operator ----------------------------------------------------------------------------------- + kubectl_bin create namespace pxc-operator ++ mktemp + local LAST_OUT=/tmp/tmp.jbG3myuZq9 ++ mktemp + local LAST_ERR=/tmp/tmp.4SMcpVA2rM + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl create namespace pxc-operator + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.jbG3myuZq9 namespace/pxc-operator created + cat /tmp/tmp.4SMcpVA2rM + rm /tmp/tmp.jbG3myuZq9 /tmp/tmp.4SMcpVA2rM + return 0 ++ kubectl_bin config current-context +++ mktemp ++ local LAST_OUT=/tmp/tmp.JZhfVszErf +++ mktemp ++ local LAST_ERR=/tmp/tmp.cviT1zjfBb ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl config current-context ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.JZhfVszErf ++ cat /tmp/tmp.cviT1zjfBb ++ rm /tmp/tmp.JZhfVszErf /tmp/tmp.cviT1zjfBb ++ return 0 + kubectl_bin config set-context gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5 --namespace=pxc-operator ++ mktemp + local LAST_OUT=/tmp/tmp.BV1nrWG9sF ++ mktemp + local LAST_ERR=/tmp/tmp.SDQZOs3wID + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl config set-context gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5 --namespace=pxc-operator + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.BV1nrWG9sF Context "gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5" modified. + cat /tmp/tmp.SDQZOs3wID + rm /tmp/tmp.BV1nrWG9sF /tmp/tmp.SDQZOs3wID + return 0 + deploy_operator + desc 'start PXC operator' + set +o xtrace ----------------------------------------------------------------------------------- start PXC operator ----------------------------------------------------------------------------------- + kubectl_bin apply --server-side --force-conflicts -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/deploy/crd.yaml ++ mktemp + local LAST_OUT=/tmp/tmp.xvXi9TvSCo ++ mktemp + local LAST_ERR=/tmp/tmp.TSJRVYQVwJ + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply --server-side --force-conflicts -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/deploy/crd.yaml + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.xvXi9TvSCo customresourcedefinition.apiextensions.k8s.io/perconaxtradbclusterbackups.pxc.percona.com serverside-applied customresourcedefinition.apiextensions.k8s.io/perconaxtradbclusterrestores.pxc.percona.com serverside-applied customresourcedefinition.apiextensions.k8s.io/perconaxtradbclusters.pxc.percona.com serverside-applied + cat /tmp/tmp.TSJRVYQVwJ + rm /tmp/tmp.xvXi9TvSCo /tmp/tmp.TSJRVYQVwJ + return 0 + '[' -n pxc-operator ']' + apply_rbac cw-rbac + local operator_namespace=pxc-operator + local rbac=cw-rbac + sed -e 's^namespace: .*^namespace: pxc-operator^' + kubectl_bin apply -f - + cat /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/deploy/cw-rbac.yaml ++ mktemp + local LAST_OUT=/tmp/tmp.ToMGiT2FcF ++ mktemp + local LAST_ERR=/tmp/tmp.tdn3rLfiZX + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.ToMGiT2FcF clusterrole.rbac.authorization.k8s.io/percona-xtradb-cluster-operator unchanged serviceaccount/percona-xtradb-cluster-operator created clusterrolebinding.rbac.authorization.k8s.io/service-account-percona-xtradb-cluster-operator unchanged + cat /tmp/tmp.tdn3rLfiZX + rm /tmp/tmp.ToMGiT2FcF /tmp/tmp.tdn3rLfiZX + return 0 + cat /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/deploy/cw-operator.yaml + sed -e 's^image: .*^image: perconalab/percona-xtradb-cluster-operator:PR-2002-42929599^' + sed -e 's^failureThreshold: .*^failureThreshold: 10^' + kubectl_bin apply -f - + yq eval '(select(.kind == "Deployment").spec.template.spec.containers[] | select(.name == "percona-xtradb-cluster-operator").env[] | select(.name == "LOG_LEVEL").value) = "VERBOSE"' - + yq eval '(select(.kind == "Deployment").spec.template.spec.containers[] | select(.name == "percona-xtradb-cluster-operator").env[] | select(.name == "DISABLE_TELEMETRY").value) = "true"' - ++ mktemp + local LAST_OUT=/tmp/tmp.eazX864Mwz ++ mktemp + local LAST_ERR=/tmp/tmp.IOXaTG2w2l + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.eazX864Mwz deployment.apps/percona-xtradb-cluster-operator created service/percona-xtradb-cluster-operator created + cat /tmp/tmp.IOXaTG2w2l + rm /tmp/tmp.eazX864Mwz /tmp/tmp.IOXaTG2w2l + return 0 + sleep 10 + kubectl_bin wait --for=condition=Ready pods -l app.kubernetes.io/component=operator,app.kubernetes.io/instance=percona-xtradb-cluster-operator,app.kubernetes.io/name=percona-xtradb-cluster-operator --timeout=30s ++ mktemp + local LAST_OUT=/tmp/tmp.Di9o396QTK ++ mktemp + local LAST_ERR=/tmp/tmp.9Cj7ngLKsI + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl wait --for=condition=Ready pods -l app.kubernetes.io/component=operator,app.kubernetes.io/instance=percona-xtradb-cluster-operator,app.kubernetes.io/name=percona-xtradb-cluster-operator --timeout=30s + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.Di9o396QTK pod/percona-xtradb-cluster-operator-6c8dc776-bhgvq condition met + cat /tmp/tmp.9Cj7ngLKsI + rm /tmp/tmp.Di9o396QTK /tmp/tmp.9Cj7ngLKsI + return 0 ++ get_operator_pod ++ local label_prefix=app.kubernetes.io/ +++ kubectl get pods --selector=app.kubernetes.io/name=percona-xtradb-cluster-operator -n pxc-operator +++ grep -c percona-xtradb-cluster-operator ++ local check_label=1 ++ [[ 1 -eq 0 ]] ++ kubectl_bin get pods --selector=app.kubernetes.io/name=percona-xtradb-cluster-operator -o 'jsonpath={.items[].metadata.name}' -n pxc-operator +++ mktemp ++ local LAST_OUT=/tmp/tmp.3XtjY658Hb +++ mktemp ++ local LAST_ERR=/tmp/tmp.b2pmW0lKHu ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=app.kubernetes.io/name=percona-xtradb-cluster-operator -o 'jsonpath={.items[].metadata.name}' -n pxc-operator ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.3XtjY658Hb ++ cat /tmp/tmp.b2pmW0lKHu ++ rm /tmp/tmp.3XtjY658Hb /tmp/tmp.b2pmW0lKHu ++ return 0 + wait_pod percona-xtradb-cluster-operator-6c8dc776-bhgvq 480 pxc-operator + local pod=percona-xtradb-cluster-operator-6c8dc776-bhgvq + local max_retry=480 + local ns=pxc-operator ++ echo percona-xtradb-cluster-operator-6c8dc776-bhgvq ++ egrep '^(pxc|proxysql)$' ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' + local container= + set +o xtrace pod/percona-xtradb-cluster-operator-6c8dc776-bhgvq condition met waiting for pod/percona-xtradb-cluster-operator-6c8dc776-bhgvq to become Ready.Ok + sleep 3 + create_namespace security-context-29660 + local namespace=security-context-29660 + local skip_clean_namespace= + [[ 1 == 1 ]] + [[ -z '' ]] + destroy_chaos_mesh ++ helm list --all-namespaces --filter chaos-mesh ++ sed s/NAMESPACE// ++ awk '-F ' '{print $2}' ++ tail -n1 + local chaos_mesh_ns= + '[' -n '' ']' ++ kubectl get MutatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete MutatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ awk '{print $1}' ++ grep validate-auth ++ kubectl get ValidatingWebhookConfiguration + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl api-resources ++ grep chaos-mesh ++ awk '{print $1}' ++ kubectl get crd ++ grep chaos-mesh.org ++ awk '{print $1}' + timeout 30 kubectl delete crd error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrolebinding ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrolebinding error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrole ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrole error: resource(s) were provided, but no name was specified + : + desc 'cleaned up all old namespaces' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up all old namespaces ----------------------------------------------------------------------------------- + egrep -v '^kube-|^default|Terminating|pxc-operator|openshift|^gke-|^gmp-|^NAME' + awk '{print$1}' + kubectl_bin get ns + '[' -n '' ']' + desc 'cleaned up old namespaces security-context-29660' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up old namespaces security-context-29660 ----------------------------------------------------------------------------------- + kubectl_bin delete namespace security-context-29660 + xargs kubectl delete ns ++ mktemp ++ mktemp + local LAST_OUT=/tmp/tmp.dne5pSlmtL ++ mktemp + local LAST_OUT=/tmp/tmp.dDkCNIgFVC ++ mktemp + local LAST_ERR=/tmp/tmp.Zr6jQRqbn8 + local exit_status=0 + local LAST_ERR=/tmp/tmp.pBdSfEXTm0 + local exit_status=0 ++ seq 0 2 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + for i in '$(seq 0 2)' + set +e + kubectl get ns + kubectl delete namespace security-context-29660 + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + for i in '$(seq 0 2)' + set +e + kubectl delete namespace security-context-29660 + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.dDkCNIgFVC + cat /tmp/tmp.Zr6jQRqbn8 + rm /tmp/tmp.dDkCNIgFVC /tmp/tmp.Zr6jQRqbn8 + return 0 error: resource(s) were provided, but no name was specified + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + for i in '$(seq 0 2)' + set +e + kubectl delete namespace security-context-29660 + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + cat /tmp/tmp.dne5pSlmtL + cat /tmp/tmp.pBdSfEXTm0 Error from server (NotFound): namespaces "security-context-29660" not found + rm /tmp/tmp.dne5pSlmtL /tmp/tmp.pBdSfEXTm0 + return 1 + : + wait_for_delete namespace/security-context-29660 + local res=namespace/security-context-29660 + echo -n 'waiting for namespace/security-context-29660 to be deleted' waiting for namespace/security-context-29660 to be deleted+ set +o xtrace Error from server (NotFound): namespaces "security-context-29660" not found + desc 'create namespace security-context-29660' + set +o xtrace ----------------------------------------------------------------------------------- create namespace security-context-29660 ----------------------------------------------------------------------------------- + kubectl_bin create namespace security-context-29660 ++ mktemp + local LAST_OUT=/tmp/tmp.gh5tDii3vu ++ mktemp + local LAST_ERR=/tmp/tmp.9Gvnk5eoBY + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl create namespace security-context-29660 + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.gh5tDii3vu namespace/security-context-29660 created + cat /tmp/tmp.9Gvnk5eoBY + rm /tmp/tmp.gh5tDii3vu /tmp/tmp.9Gvnk5eoBY + return 0 ++ kubectl_bin config current-context +++ mktemp ++ local LAST_OUT=/tmp/tmp.dhnW01adsZ +++ mktemp ++ local LAST_ERR=/tmp/tmp.WI2EeEtjgL ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl config current-context ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.dhnW01adsZ ++ cat /tmp/tmp.WI2EeEtjgL ++ rm /tmp/tmp.dhnW01adsZ /tmp/tmp.WI2EeEtjgL ++ return 0 + kubectl_bin config set-context gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5 --namespace=security-context-29660 ++ mktemp + local LAST_OUT=/tmp/tmp.VvSNm9XgD5 ++ mktemp + local LAST_ERR=/tmp/tmp.HDkNxxcrHf + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl config set-context gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5 --namespace=security-context-29660 + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.VvSNm9XgD5 Context "gke_cloud-dev-112233_us-central1-a_jen-pxc-2002-42929599-9-cluster5" modified. + cat /tmp/tmp.HDkNxxcrHf + rm /tmp/tmp.VvSNm9XgD5 /tmp/tmp.HDkNxxcrHf + return 0 + apply_secrets + desc 'create secrets for cloud storages' + set +o xtrace ----------------------------------------------------------------------------------- create secrets for cloud storages ----------------------------------------------------------------------------------- + '[' -z '' ']' + kubectl_bin apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/minio-secret.yml -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/cloud-secret.yml ++ mktemp + local LAST_OUT=/tmp/tmp.aD6vjBsNoY ++ mktemp + local LAST_ERR=/tmp/tmp.UZKAjQJydW + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/minio-secret.yml -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/cloud-secret.yml + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.aD6vjBsNoY secret/minio-secret created secret/aws-s3-secret created secret/gcp-cs-secret created secret/azure-secret created + cat /tmp/tmp.UZKAjQJydW + rm /tmp/tmp.aD6vjBsNoY /tmp/tmp.UZKAjQJydW + return 0 + deploy_cert_manager + desc 'deploy cert manager' + set +o xtrace ----------------------------------------------------------------------------------- deploy cert manager ----------------------------------------------------------------------------------- + kubectl_bin create namespace cert-manager ++ mktemp + local LAST_OUT=/tmp/tmp.h3Tt7lVTKc ++ mktemp + local LAST_ERR=/tmp/tmp.Rv2e1UXh7S + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl create namespace cert-manager + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.h3Tt7lVTKc namespace/cert-manager created + cat /tmp/tmp.Rv2e1UXh7S + rm /tmp/tmp.h3Tt7lVTKc /tmp/tmp.Rv2e1UXh7S + return 0 + kubectl_bin label namespace cert-manager certmanager.k8s.io/disable-validation=true ++ mktemp + local LAST_OUT=/tmp/tmp.MMsx67VQHJ ++ mktemp + local LAST_ERR=/tmp/tmp.PWkwN6u9Op + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl label namespace cert-manager certmanager.k8s.io/disable-validation=true + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.MMsx67VQHJ namespace/cert-manager labeled + cat /tmp/tmp.PWkwN6u9Op + rm /tmp/tmp.MMsx67VQHJ /tmp/tmp.PWkwN6u9Op + return 0 + kubectl_bin apply -f https://github.com/jetstack/cert-manager/releases/download/v1.18.2/cert-manager.yaml --validate=false ++ mktemp + local LAST_OUT=/tmp/tmp.XG7h7NRR1T ++ mktemp + local LAST_ERR=/tmp/tmp.MHdzD9yCUB + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.18.2/cert-manager.yaml --validate=false + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.XG7h7NRR1T namespace/cert-manager configured customresourcedefinition.apiextensions.k8s.io/certificaterequests.cert-manager.io unchanged customresourcedefinition.apiextensions.k8s.io/certificates.cert-manager.io unchanged customresourcedefinition.apiextensions.k8s.io/challenges.acme.cert-manager.io unchanged customresourcedefinition.apiextensions.k8s.io/clusterissuers.cert-manager.io unchanged customresourcedefinition.apiextensions.k8s.io/issuers.cert-manager.io unchanged customresourcedefinition.apiextensions.k8s.io/orders.acme.cert-manager.io unchanged serviceaccount/cert-manager-cainjector created serviceaccount/cert-manager created serviceaccount/cert-manager-webhook created clusterrole.rbac.authorization.k8s.io/cert-manager-cainjector unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-issuers unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificates unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-orders unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-challenges unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-cluster-view unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-view unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-edit unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests unchanged clusterrole.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-cainjector unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-issuers unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificates unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-orders unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-challenges unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests unchanged clusterrolebinding.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews unchanged role.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection unchanged role.rbac.authorization.k8s.io/cert-manager:leaderelection unchanged role.rbac.authorization.k8s.io/cert-manager-tokenrequest created role.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created rolebinding.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection unchanged rolebinding.rbac.authorization.k8s.io/cert-manager:leaderelection unchanged rolebinding.rbac.authorization.k8s.io/cert-manager-cert-manager-tokenrequest created rolebinding.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created service/cert-manager-cainjector created service/cert-manager created service/cert-manager-webhook created deployment.apps/cert-manager-cainjector created deployment.apps/cert-manager created deployment.apps/cert-manager-webhook created mutatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook configured validatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook configured + cat /tmp/tmp.MHdzD9yCUB Warning: resource namespaces/cert-manager is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically. + rm /tmp/tmp.XG7h7NRR1T /tmp/tmp.MHdzD9yCUB + return 0 + '[' '' == 4.10 ']' + sleep 70 + kubectl_bin apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/service-account.yml ++ mktemp + local LAST_OUT=/tmp/tmp.nwXPkG0S7O ++ mktemp + local LAST_ERR=/tmp/tmp.alvlCe1T9V + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/service-account.yml + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.nwXPkG0S7O serviceaccount/percona-xtradb-cluster-operator-workload created + cat /tmp/tmp.alvlCe1T9V + rm /tmp/tmp.nwXPkG0S7O /tmp/tmp.alvlCe1T9V + return 0 + [[ -n '' ]] + desc 'create first PXC cluster' + set +o xtrace ----------------------------------------------------------------------------------- create first PXC cluster ----------------------------------------------------------------------------------- + cluster=sec-context + spinup_pxc sec-context /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/sec-context.yml 3 10 /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/secrets_without_tls.yml + local cluster=sec-context + local config=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/sec-context.yml + local size=3 + local sleep=10 + local secretsFile=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/secrets_without_tls.yml + local pxcClientFile=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/client.yml + local port=3306 + desc 'create first PXC cluster' + set +o xtrace ----------------------------------------------------------------------------------- create first PXC cluster ----------------------------------------------------------------------------------- + kubectl_bin apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/secrets_without_tls.yml ++ mktemp + local LAST_OUT=/tmp/tmp.a0rGpe0WqN ++ mktemp + local LAST_ERR=/tmp/tmp.dRfDOK8UsO + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/secrets_without_tls.yml + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.a0rGpe0WqN secret/my-cluster-secrets created + cat /tmp/tmp.dRfDOK8UsO + rm /tmp/tmp.a0rGpe0WqN /tmp/tmp.dRfDOK8UsO + return 0 + apply_config /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/client.yml + '[' -z '' ']' + cat_config /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/client.yml + kubectl_bin apply -f - + cat /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/conf/client.yml + /usr/bin/sed -e 's#apiVersion: pxc.percona.com/v.*$#apiVersion: pxc.percona.com/v1#' ++ mktemp + /usr/bin/sed -e 's#image:.*\/percona-xtradb-cluster:.*$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0#' + /usr/bin/sed -e 's#image:.*-pxc\([0-9]*.[0-9]*\)\{0,1\}$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0#' + /usr/bin/sed -e 's#image:.*-init$#image: perconalab/percona-xtradb-cluster-operator:PR-2002-42929599#' + /usr/bin/sed -e 's#image:.*-pmm$#image: perconalab/pmm-client:dev-latest#' + /usr/bin/sed -e 's#image:.*-proxysql$#image: perconalab/percona-xtradb-cluster-operator:main-proxysql#' + /usr/bin/sed -e 's#image:.*-backup$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0-backup#' + /usr/bin/sed -e 's#apply:.*#apply: Never#' + /usr/bin/sed -e 's#image:.*-haproxy$#image: perconalab/percona-xtradb-cluster-operator:main-haproxy#' + /usr/bin/sed -e 's#image:.*-logcollector$#image: perconalab/percona-xtradb-cluster-operator:main-logcollector#' + /usr/bin/sed -e s~minio-service.#namespace~minio-service.security-context-29660~ + local LAST_OUT=/tmp/tmp.mjHtD6yTYb ++ mktemp + local LAST_ERR=/tmp/tmp.EVfHYjZ51q + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.mjHtD6yTYb deployment.apps/pxc-client created + cat /tmp/tmp.EVfHYjZ51q + rm /tmp/tmp.mjHtD6yTYb /tmp/tmp.EVfHYjZ51q + return 0 + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 5\.7 ]] + apply_config /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/sec-context.yml + '[' -z '' ']' + cat_config /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/sec-context.yml + /usr/bin/sed -e 's#image:.*-logcollector$#image: perconalab/percona-xtradb-cluster-operator:main-logcollector#' + /usr/bin/sed -e 's#image:.*-haproxy$#image: perconalab/percona-xtradb-cluster-operator:main-haproxy#' + /usr/bin/sed -e 's#image:.*-init$#image: perconalab/percona-xtradb-cluster-operator:PR-2002-42929599#' + /usr/bin/sed -e 's#image:.*\/percona-xtradb-cluster:.*$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0#' + kubectl_bin apply -f - + /usr/bin/sed -e 's#image:.*-pmm$#image: perconalab/pmm-client:dev-latest#' + /usr/bin/sed -e 's#image:.*-backup$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0-backup#' + /usr/bin/sed -e s~minio-service.#namespace~minio-service.security-context-29660~ + /usr/bin/sed -e 's#image:.*-proxysql$#image: perconalab/percona-xtradb-cluster-operator:main-proxysql#' + cat /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/conf/sec-context.yml + /usr/bin/sed -e 's#apiVersion: pxc.percona.com/v.*$#apiVersion: pxc.percona.com/v1#' + /usr/bin/sed -e 's#image:.*-pxc\([0-9]*.[0-9]*\)\{0,1\}$#image: perconalab/percona-xtradb-cluster-operator:main-pxc8.0#' + /usr/bin/sed -e 's#apply:.*#apply: Never#' ++ mktemp + local LAST_OUT=/tmp/tmp.rJq7PxoddZ ++ mktemp + local LAST_ERR=/tmp/tmp.uQEtv5kR4o + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.rJq7PxoddZ perconaxtradbcluster.pxc.percona.com/sec-context created + cat /tmp/tmp.uQEtv5kR4o + rm /tmp/tmp.rJq7PxoddZ /tmp/tmp.uQEtv5kR4o + return 0 + desc 'check if all 3 Pods started' + set +o xtrace ----------------------------------------------------------------------------------- check if all 3 Pods started ----------------------------------------------------------------------------------- ++ get_proxy sec-context ++ local target_cluster=sec-context +++ kubectl_bin get pxc sec-context -o 'jsonpath={.spec.haproxy.enabled}' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.tAZojLtZ36 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.BcBsPgw7Fe +++ local exit_status=0 ++++ seq 0 2 +++ for i in '$(seq 0 2)' +++ set +e +++ kubectl get pxc sec-context -o 'jsonpath={.spec.haproxy.enabled}' +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 ']' +++ break +++ cat /tmp/tmp.tAZojLtZ36 +++ cat /tmp/tmp.BcBsPgw7Fe +++ rm /tmp/tmp.tAZojLtZ36 /tmp/tmp.BcBsPgw7Fe +++ return 0 ++ [[ '' == \t\r\u\e ]] +++ kubectl_bin get pxc sec-context -o 'jsonpath={.spec.proxysql.enabled}' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.6wNmFrLPj3 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.1Ftk0QKMRz +++ local exit_status=0 ++++ seq 0 2 +++ for i in '$(seq 0 2)' +++ set +e +++ kubectl get pxc sec-context -o 'jsonpath={.spec.proxysql.enabled}' +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 ']' +++ break +++ cat /tmp/tmp.6wNmFrLPj3 +++ cat /tmp/tmp.1Ftk0QKMRz +++ rm /tmp/tmp.6wNmFrLPj3 /tmp/tmp.1Ftk0QKMRz +++ return 0 ++ [[ true == \t\r\u\e ]] ++ echo sec-context-proxysql ++ return + local proxy=sec-context-proxysql + kubectl_bin wait --for=condition=Ready pod -l app.kubernetes.io/instance=monitoring,app.kubernetes.io/managed-by=percona-xtradb-cluster-operator --timeout=300s -n security-context-29660 ++ mktemp + local LAST_OUT=/tmp/tmp.5FdVW7jf6C ++ mktemp + local LAST_ERR=/tmp/tmp.qingZIVfcF + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl wait --for=condition=Ready pod -l app.kubernetes.io/instance=monitoring,app.kubernetes.io/managed-by=percona-xtradb-cluster-operator --timeout=300s -n security-context-29660 + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + for i in '$(seq 0 2)' + set +e + kubectl wait --for=condition=Ready pod -l app.kubernetes.io/instance=monitoring,app.kubernetes.io/managed-by=percona-xtradb-cluster-operator --timeout=300s -n security-context-29660 + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + for i in '$(seq 0 2)' + set +e + kubectl wait --for=condition=Ready pod -l app.kubernetes.io/instance=monitoring,app.kubernetes.io/managed-by=percona-xtradb-cluster-operator --timeout=300s -n security-context-29660 + exit_status=1 + set -e + '[' 1 '!=' 0 ']' + '[' 1 == 1 ']' + sleep 0 + cat /tmp/tmp.5FdVW7jf6C + cat /tmp/tmp.qingZIVfcF error: no matching resources found + rm /tmp/tmp.5FdVW7jf6C /tmp/tmp.qingZIVfcF + return 1 + true + wait_for_running sec-context-proxysql 1 + local name=sec-context-proxysql + let last_pod=0 + : + local max_retry=480 + desc 'wait for running cluster' + set +o xtrace ----------------------------------------------------------------------------------- wait for running cluster ----------------------------------------------------------------------------------- ++ seq 0 0 + for i in '$(seq 0 $last_pod)' + wait_pod sec-context-proxysql-0 480 + local pod=sec-context-proxysql-0 + local max_retry=480 + local ns= ++ echo sec-context-proxysql-0 ++ egrep '^(pxc|proxysql)$' ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' + local container=proxysql + set +o xtrace pod/sec-context-proxysql-0 condition met waiting for pod/sec-context-proxysql-0 to become Ready.Ok + wait_for_running sec-context-pxc 3 + local name=sec-context-pxc + let last_pod=2 + local max_retry=480 + desc 'wait for running cluster' + set +o xtrace ----------------------------------------------------------------------------------- wait for running cluster ----------------------------------------------------------------------------------- ++ seq 0 2 + for i in '$(seq 0 $last_pod)' + wait_pod sec-context-pxc-0 480 + local pod=sec-context-pxc-0 + local max_retry=480 + local ns= ++ echo sec-context-pxc-0 ++ egrep '^(pxc|proxysql)$' ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' + local container=pxc + set +o xtrace pod/sec-context-pxc-0 condition met waiting for pod/sec-context-pxc-0 to become Ready.Ok + for i in '$(seq 0 $last_pod)' + wait_pod sec-context-pxc-1 480 + local pod=sec-context-pxc-1 + local max_retry=480 + local ns= ++ echo sec-context-pxc-1 ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ egrep '^(pxc|proxysql)$' + local container=pxc + set +o xtrace pod/sec-context-pxc-1 condition met waiting for pod/sec-context-pxc-1 to become Ready.Ok + for i in '$(seq 0 $last_pod)' + wait_pod sec-context-pxc-2 480 + local pod=sec-context-pxc-2 + local max_retry=480 + local ns= ++ echo sec-context-pxc-2 ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ egrep '^(pxc|proxysql)$' + local container=pxc + set +o xtrace pod/sec-context-pxc-2 condition met waiting for pod/sec-context-pxc-2 to become Ready.Ok + sleep 10 ++ kubectl get pxc sec-context -o 'jsonpath={.spec.secretsName}' + local secret_name=my-cluster-secrets ++ getSecretData my-cluster-secrets root ++ local secretName=my-cluster-secrets ++ local dataKey=root ++ kubectl_bin get secrets/my-cluster-secrets '--template={{.data.root}}' ++ base64 --decode +++ mktemp ++ local LAST_OUT=/tmp/tmp.kaYR310EBK +++ mktemp ++ local LAST_ERR=/tmp/tmp.SmbCeLmYT8 ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get secrets/my-cluster-secrets '--template={{.data.root}}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.kaYR310EBK ++ cat /tmp/tmp.SmbCeLmYT8 ++ rm /tmp/tmp.kaYR310EBK /tmp/tmp.SmbCeLmYT8 ++ return 0 + local root_pass=root_password + desc 'write data' + set +o xtrace ----------------------------------------------------------------------------------- write data ----------------------------------------------------------------------------------- + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 5\.7 ]] + run_mysql 'CREATE DATABASE IF NOT EXISTS myApp; use myApp; CREATE TABLE IF NOT EXISTS myApp (id int PRIMARY KEY) ;' '-h sec-context-proxysql -uroot -p'\''root_password'\'' -P3306' + local 'command=CREATE DATABASE IF NOT EXISTS myApp; use myApp; CREATE TABLE IF NOT EXISTS myApp (id int PRIMARY KEY) ;' + local 'uri=-h sec-context-proxysql -uroot -p'\''root_password'\'' -P3306' ++ get_client_pod ++ kubectl_bin get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.o5sNmFICxP +++ mktemp ++ local LAST_ERR=/tmp/tmp.F8U9j01uR4 ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.o5sNmFICxP ++ cat /tmp/tmp.F8U9j01uR4 ++ rm /tmp/tmp.o5sNmFICxP /tmp/tmp.F8U9j01uR4 ++ return 0 + client_pod=pxc-client-59944c5bbf-twb6z + wait_pod pxc-client-59944c5bbf-twb6z + local pod=pxc-client-59944c5bbf-twb6z + local max_retry=480 + local ns= ++ echo pxc-client-59944c5bbf-twb6z ++ egrep '^(pxc|proxysql)$' ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' + local container= + set +o xtrace pod/pxc-client-59944c5bbf-twb6z condition met waiting for pod/pxc-client-59944c5bbf-twb6z to become ReadyDefaulted container "pxc-client" out of: pxc-client, backup .Ok + set +o xtrace + run_mysql 'INSERT myApp.myApp (id) VALUES (100500)' '-h sec-context-proxysql -uroot -p'\''root_password'\'' -P3306' + local 'command=INSERT myApp.myApp (id) VALUES (100500)' + local 'uri=-h sec-context-proxysql -uroot -p'\''root_password'\'' -P3306' ++ get_client_pod ++ kubectl_bin get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.FjSdcfH9sI +++ mktemp ++ local LAST_ERR=/tmp/tmp.bWVQuGQc3S ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.FjSdcfH9sI ++ cat /tmp/tmp.bWVQuGQc3S ++ rm /tmp/tmp.FjSdcfH9sI /tmp/tmp.bWVQuGQc3S ++ return 0 + client_pod=pxc-client-59944c5bbf-twb6z + wait_pod pxc-client-59944c5bbf-twb6z + local pod=pxc-client-59944c5bbf-twb6z + local max_retry=480 + local ns= ++ echo pxc-client-59944c5bbf-twb6z ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ egrep '^(pxc|proxysql)$' + local container= + set +o xtrace pod/pxc-client-59944c5bbf-twb6z condition met waiting for pod/pxc-client-59944c5bbf-twb6z to become ReadyDefaulted container "pxc-client" out of: pxc-client, backup .Ok + set +o xtrace + sleep 30 ++ seq 0 2 + for i in '$(seq 0 $((size - 1)))' + compare_mysql_cmd select-1 'SELECT * from myApp.myApp;' '-h sec-context-pxc-0.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local command_id=select-1 + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-0.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local postfix= + local expected_result=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.4 ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.0 ]] + [[ -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1-80.sql ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 5\.7 ]] + run_mysql 'SELECT * from myApp.myApp;' '-h sec-context-pxc-0.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-0.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' ++ get_client_pod ++ kubectl_bin get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.cWkjWVpxfp +++ mktemp ++ local LAST_ERR=/tmp/tmp.n7UDJOjIxC ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.cWkjWVpxfp ++ cat /tmp/tmp.n7UDJOjIxC ++ rm /tmp/tmp.cWkjWVpxfp /tmp/tmp.n7UDJOjIxC ++ return 0 + client_pod=pxc-client-59944c5bbf-twb6z + wait_pod pxc-client-59944c5bbf-twb6z + local pod=pxc-client-59944c5bbf-twb6z + local max_retry=480 + local ns= ++ egrep '^(pxc|proxysql)$' ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ echo pxc-client-59944c5bbf-twb6z + local container= + set +o xtrace pod/pxc-client-59944c5bbf-twb6z condition met waiting for pod/pxc-client-59944c5bbf-twb6z to become ReadyDefaulted container "pxc-client" out of: pxc-client, backup .Ok + set +o xtrace + '[' '!' -s /tmp/tmp.whMIzk1c8m/select-1.sql ']' + diff -u /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql /tmp/tmp.whMIzk1c8m/select-1.sql + for i in '$(seq 0 $((size - 1)))' + compare_mysql_cmd select-1 'SELECT * from myApp.myApp;' '-h sec-context-pxc-1.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local command_id=select-1 + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-1.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local postfix= + local expected_result=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.4 ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.0 ]] + [[ -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1-80.sql ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 5\.7 ]] + run_mysql 'SELECT * from myApp.myApp;' '-h sec-context-pxc-1.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-1.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' ++ get_client_pod ++ kubectl_bin get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.eiKGxSVvWZ +++ mktemp ++ local LAST_ERR=/tmp/tmp.FytdjOXuak ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.eiKGxSVvWZ ++ cat /tmp/tmp.FytdjOXuak ++ rm /tmp/tmp.eiKGxSVvWZ /tmp/tmp.FytdjOXuak ++ return 0 + client_pod=pxc-client-59944c5bbf-twb6z + wait_pod pxc-client-59944c5bbf-twb6z + local pod=pxc-client-59944c5bbf-twb6z + local max_retry=480 + local ns= ++ echo pxc-client-59944c5bbf-twb6z ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ egrep '^(pxc|proxysql)$' + local container= + set +o xtrace pod/pxc-client-59944c5bbf-twb6z condition met waiting for pod/pxc-client-59944c5bbf-twb6z to become ReadyDefaulted container "pxc-client" out of: pxc-client, backup .Ok + set +o xtrace + '[' '!' -s /tmp/tmp.whMIzk1c8m/select-1.sql ']' + diff -u /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql /tmp/tmp.whMIzk1c8m/select-1.sql + for i in '$(seq 0 $((size - 1)))' + compare_mysql_cmd select-1 'SELECT * from myApp.myApp;' '-h sec-context-pxc-2.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local command_id=select-1 + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-2.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local postfix= + local expected_result=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.4 ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.0 ]] + [[ -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1-80.sql ]] + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 5\.7 ]] + run_mysql 'SELECT * from myApp.myApp;' '-h sec-context-pxc-2.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' + local 'command=SELECT * from myApp.myApp;' + local 'uri=-h sec-context-pxc-2.sec-context-pxc -uroot -p'\''root_password'\'' -P3306' ++ get_client_pod ++ kubectl_bin get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.CfbGRRCapm +++ mktemp ++ local LAST_ERR=/tmp/tmp.azQ2bUEaJq ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl get pods --selector=name=pxc-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.CfbGRRCapm ++ cat /tmp/tmp.azQ2bUEaJq ++ rm /tmp/tmp.CfbGRRCapm /tmp/tmp.azQ2bUEaJq ++ return 0 + client_pod=pxc-client-59944c5bbf-twb6z + wait_pod pxc-client-59944c5bbf-twb6z + local pod=pxc-client-59944c5bbf-twb6z + local max_retry=480 + local ns= ++ echo pxc-client-59944c5bbf-twb6z ++ /usr/bin/sed -E 's/.*-(pxc|proxysql)-[0-9]/\1/' ++ egrep '^(pxc|proxysql)$' + local container= + set +o xtrace pod/pxc-client-59944c5bbf-twb6z condition met waiting for pod/pxc-client-59944c5bbf-twb6z to become ReadyDefaulted container "pxc-client" out of: pxc-client, backup .Ok + set +o xtrace + '[' '!' -s /tmp/tmp.whMIzk1c8m/select-1.sql ']' + diff -u /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/select-1.sql /tmp/tmp.whMIzk1c8m/select-1.sql ++ is_keyring_plugin_in_use sec-context ++ local cluster=sec-context ++ kubectl_bin exec -it sec-context-pxc-0 -c pxc -- bash -c 'cat /etc/mysql/node.cnf' ++ egrep -o 'early-plugin-load=keyring_\w+.so' +++ mktemp ++ local LAST_OUT=/tmp/tmp.yDDOIJdGC9 +++ mktemp ++ local LAST_ERR=/tmp/tmp.OXf1S2z8t1 ++ local exit_status=0 +++ seq 0 2 ++ for i in '$(seq 0 2)' ++ set +e ++ kubectl exec -it sec-context-pxc-0 -c pxc -- bash -c 'cat /etc/mysql/node.cnf' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 ']' ++ break ++ cat /tmp/tmp.yDDOIJdGC9 ++ cat /tmp/tmp.OXf1S2z8t1 Unable to use a TTY - input is not a terminal or the right kind of file ++ rm /tmp/tmp.yDDOIJdGC9 /tmp/tmp.OXf1S2z8t1 ++ return 0 + '[' '' ']' + desc 'check if service and statefulset created with expected config' + set +o xtrace ----------------------------------------------------------------------------------- check if service and statefulset created with expected config ----------------------------------------------------------------------------------- + compare_kubectl statefulset/sec-context-pxc + local resource=statefulset/sec-context-pxc + local postfix= + local expected_result=/mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc.yml + local new_result=/tmp/tmp.whMIzk1c8m/statefulset_sec-context-pxc.yml + desc 'compare statefulset/sec-context-pxc-' + set +o xtrace ----------------------------------------------------------------------------------- compare statefulset/sec-context-pxc- ----------------------------------------------------------------------------------- + '[' 0 = 1 -a -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-eks.yml ']' + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.0 ]] + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-80.yml ']' + [[ perconalab/percona-xtradb-cluster-operator:main-pxc8.0 =~ 8\.4 ]] + version_gt 1.33 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.33' ++ bc -l + '[' 0 -eq 1 ']' + return 1 + version_gt 1.29 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.29' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k129.yml ']' + version_gt 1.27 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.27' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k127.yml ']' + version_gt 1.24 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.24' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k124.yml ']' + version_gt 1.22 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.22' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k122.yml ']' + version_gt 1.21 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.21' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k121.yml ']' + '[' '!' -z '' -a -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-oc.yml ']' + version_gt 1.29 + desc 'return true if kubernetes version equal or greater than desired' + set +o xtrace ----------------------------------------------------------------------------------- return true if kubernetes version equal or greater than desired ----------------------------------------------------------------------------------- ++ echo '1.31 >= 1.29' ++ bc -l + '[' 1 -eq 1 ']' + return 0 + '[' '!' -z '' -a -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-k129-oc.yml ']' + '[' 0 = 1 -a -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-eks.yml ']' + '[' 0 = 1 -a -f /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc-aks.yml ']' + kubectl_bin get -o yaml statefulset/sec-context-pxc + yq eval ' del(.metadata.managedFields) | del(.. | select(has("creationTimestamp")).creationTimestamp) | del(.. | select(has("namespace")).namespace) | del(.. | select(has("uid")).uid) | del(.metadata.resourceVersion) | del(.spec.template.spec.containers[].env[] | select(.name == "CLUSTER_HASH")) | del(.spec.template.spec.containers[].env[] | select(.name == "S3_BUCKET_PATH")) | del(.spec.template.spec.containers[].env[] | select(.name == "BACKUP_PATH")) | del(.spec.template.spec.containers[].env[] | select(.name == "S3_BUCKET_URL")) | del(.spec.template.spec.containers[].env[] | select(.name == "AZURE_CONTAINER_NAME")) | del(.metadata.selfLink) | del(.metadata.deletionTimestamp) | del(.metadata.annotations."kubectl.kubernetes.io/last-applied-configuration") | del(.metadata.annotations."kubernetes.io/psp") | del(.metadata.annotations."batch.kubernetes.io/job-tracking") | del(.metadata.labels."batch.kubernetes.io/job-name") | del(.metadata.labels."job-name") | del(.metadata.annotations."cloud.google.com/neg") | del(.metadata.annotations."k8s.v1.cni.cncf.io*") | del(.metadata.annotations."k8s.ovn.org/pod-networks") | del(.spec.template.metadata.annotations."last-applied-secret") | del(.spec.template.metadata.labels."batch.kubernetes.io/job-name") | del(.spec.template.metadata.labels."job-name") | del(.. | select(has("batch.kubernetes.io/controller-uid"))."batch.kubernetes.io/controller-uid") | del(.. | select(has("image")).image) | del(.. | select(has("clusterIP")).clusterIP) | del(.. | select(has("clusterIPs")).clusterIPs) | del(.. | select(has("dataSource")).dataSource) | del(.. | select(has("procMount")).procMount) | del(.. | select(has("storageClassName")).storageClassName) | del(.. | select(has("finalizers")).finalizers) | del(.. | select(has("kubernetes.io/pvc-protection"))."kubernetes.io/pvc-protection") | del(.. | select(has("volumeName")).volumeName) | del(.. | select(has("volume.beta.kubernetes.io/storage-provisioner"))."volume.beta.kubernetes.io/storage-provisioner") | del(.. | select(has("volume.kubernetes.io/storage-provisioner"))."volume.kubernetes.io/storage-provisioner") | del(.spec.volumeMode) | del(.spec.nodeName) | del(.. | select(has("volume.kubernetes.io/selected-node"))."volume.kubernetes.io/selected-node") | del(.. | select(has("percona.com/last-config-hash"))."percona.com/last-config-hash") | del(.. | select(has("percona.com/configuration-hash"))."percona.com/configuration-hash") | del(.. | select(has("percona.com/env-secret-config-hash"))."percona.com/env-secret-config-hash") | del(.. | select(has("percona.com/ssl-hash"))."percona.com/ssl-hash") | del(.. | select(has("percona.com/ssl-internal-hash"))."percona.com/ssl-internal-hash") | del(.. | select(has("kubectl.kubernetes.io/default-container"))."kubectl.kubernetes.io/default-container") | del(.spec.volumeClaimTemplates[].spec.volumeMode | select(. == "Filesystem")) | del(.. | select(has("healthCheckNodePort")).healthCheckNodePort) | del(.. | select(has("nodePort")).nodePort) | del(.. | select(has("imagePullSecrets")).imagePullSecrets) | del(.. | select(has("enableServiceLinks")).enableServiceLinks) | del(.status) | del(.spec.volumeClaimTemplates[].apiVersion) | del(.spec.volumeClaimTemplates[].kind) | del(.metadata.ownerReferences[].apiVersion) | del(.. | select(has("controller-uid")).controller-uid) | del(.. | select(has("preemptionPolicy")).preemptionPolicy) | del(.spec.ipFamilies) | del(.spec.ipFamilyPolicy) | (.. | select(. == "policy/v1beta1")) = "policy/v1" | del(.. | select(has("kubernetes.io/hostname"))."kubernetes.io/hostname") | (.. | select(tag == "!!str")) |= sub("security-context-29660", "namespace") | (.. | select(tag == "!!str")) |= sub("kube-api-access-.*", "kube-api-access") | del(.. | select(has("annotations")).annotations | select(length==0)) | del(.spec.crVersion) | del(.. | select(.[] == "percona-xtradb-cluster-operator-workload-token*"))' - ++ mktemp + local LAST_OUT=/tmp/tmp.qEA8ZZF2Qq ++ mktemp + local LAST_ERR=/tmp/tmp.Qml1W7DO0X + local exit_status=0 ++ seq 0 2 + for i in '$(seq 0 2)' + set +e + kubectl get -o yaml statefulset/sec-context-pxc + exit_status=0 + set -e + '[' 0 '!=' 0 ']' + break + cat /tmp/tmp.qEA8ZZF2Qq + cat /tmp/tmp.Qml1W7DO0X + rm /tmp/tmp.qEA8ZZF2Qq /tmp/tmp.Qml1W7DO0X + return 0 + diff -u /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc.yml /tmp/tmp.whMIzk1c8m/statefulset_sec-context-pxc.yml --- /mnt/jenkins/workspace/cloud-pxc-operator_PR-2002/e2e-tests/security-context/compare/statefulset_sec-context-pxc.yml 2025-11-04 07:54:10.976958718 +0000 +++ /tmp/tmp.whMIzk1c8m/statefulset_sec-context-pxc.yml 2025-11-04 09:27:20.639512258 +0000 @@ -84,6 +84,8 @@ value: /var/lib/mysql/notify.sock - name: MYSQL_STATE_FILE value: /var/lib/mysql/mysql.state + - name: LD_PRELOAD + value: /usr/lib64/libjemalloc.so.1 envFrom: - secretRef: name: sec-context-env-vars-pxc