-
Bug
-
Resolution: Done
-
Critical
-
quay-v3.4.0
-
False
-
False
-
Undefined
-
Description:
This is an issue found when use Quay TNG Operator to deploy Quay, now choose to use default managed postgresql database as Quay's database, and use external un-managed AWS S3 as Quay registry Storage, after triggered Quay deployment, POD "quayregistry-quay-app-upgrade" was crashed with error message "Could not connect to database. Error: If you are using a Postgres database, you must install the pg_trgm extension". refer to TNG Operator Logs attached.
Docs: https://docs.projectquay.io/deploy_quay_on_openshift_op_tng.html#_high_level_concepts
OCP ENV:
https://console-openshift-console.apps.quay-439.qe.devcluster.openshift.com
kubeadmin/9K6cJ-Aser6-3wCjZ-VsfXh
NOTE:
With the same quay config bundle and CR on different OCP ENV, this issue can't be reproduced stably, here create this issue to investigate.
PODs Status and Logs:
lizhang@lzha-mac Downloads % oc get pod
NAME READY STATUS RESTARTS AGE
quay-operator-86d66598b8-cpqxq 1/1 Running 0 82m
quayregistry-clair-app-5449d668c4-2jk8q 1/1 Running 1 81m
quayregistry-clair-postgres-58f4b94bbc-n98xf 1/1 Running 1 81m
quayregistry-quay-app-upgrade-5649f4ccdb-b9ljm 0/1 CrashLoopBackOff 19 81m
quayregistry-quay-config-editor-546cb8994c-f5782 1/1 Running 0 81m
quayregistry-quay-database-b96c99b55-hgf7t 1/1 Running 0 81m
quayregistry-quay-mirror-757b64d558-8zrhh 0/1 Init:CrashLoopBackOff 14 81m
quayregistry-quay-postgres-init-srjsc 0/1 Completed 0 81m
quayregistry-quay-redis-d98744d58-86m25 1/1 Running 0 81m
Index Image:
registry-proxy.engineering.redhat.com/rh-osbs/iib:30546
Quay Operator Image:
lizhang@lzha-mac Downloads % oc get pod quay-operator-86d66598b8-cpqxq -o json | jq '.spec.containers[0].image' "registry.redhat.io/quay/quay-rhel8-operator@sha256:079cae91a19aa3dde547c399c8f7478aa9cc437aadc9a309c4b313e39f743d24"
Quay config.yaml:
SUPER_USERS: - quay - admin DISTRIBUTED_STORAGE_DEFAULT_LOCATIONS: - default DISTRIBUTED_STORAGE_PREFERENCE: - default DISTRIBUTED_STORAGE_CONFIG: default: - S3Storage - s3_bucket: awsquay1115 storage_path: /datafile s3_access_key: ****** s3_secret_key: ****** host: s3.us-east-2.amazonaws.com
Quay Registry CR:
apiVersion: quay.redhat.com/v1
kind: QuayRegistry
metadata:
name: quayregistry
spec:
configBundleSecret: test-config-bundle
components:
- kind: objectstorage
managed: false
Steps:
- Create new OCP Namespace
- Deploy Quay V3.4.0 with TNG operator to above new OCP Namespace
- Create quay config bundle with "oc create secret generic --from-file config.yaml=./config.yaml test-config-bundle"
- Create new Quayregistry CR
- Check all Pods status
Expected Results:
All Pods are in ready status.
Actual Results:
Quay app upgrade PODs was failed to start with error message "Could not connect to database. Error: If you are using a Postgres database, you must install the pg_trgm extension"