3.3. 配置数据库
3.3.1. 使用现有的 Postgres 数据库 复制链接链接已复制到粘贴板!
复制链接链接已复制到粘贴板!
使用所需的数据库字段创建配置文件
config.yaml
:config.yaml:
DB_URI: postgresql://test-quay-database:postgres@test-quay-database:5432/test-quay-database
DB_URI: postgresql://test-quay-database:postgres@test-quay-database:5432/test-quay-database
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 使用配置文件创建 Secret:
kubectl create secret generic --from-file config.yaml=./config.yaml config-bundle-secret
$ kubectl create secret generic --from-file config.yaml=./config.yaml config-bundle-secret
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 创建 QuayRegistry YAML 文件
quayregistry.yaml
,将postgres
组件标记为非受管状态,并引用所创建的 Secret:quayregistry.yaml
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 按照以下部分所述部署 registry。