2.2.4.7.4. system-postgresql DeploymentConfig
現在の 3scale インストール環境に system-postgresql DeploymentConfig が存在する場合は、system-postgresql 用の PostgreSQL イメージにパッチを適用します。
system-postgresqlイメージストリームにパッチを適用します。oc patch imagestream/system-postgresql --type=json -p '[{"op": "add", "path": "/spec/tags/-", "value": {"annotations": {"openshift.io/display-name": "System 2.9 PostgreSQL"}, "from": { "kind": "DockerImage", "name": "registry.redhat.io/rhscl/postgresql-10-rhel7"}, "name": "2.9", "referencePolicy": {"type": "Source"}}}]'oc patch imagestream/system-postgresql --type=json -p '[{"op": "add", "path": "/spec/tags/-", "value": {"annotations": {"openshift.io/display-name": "System 2.9 PostgreSQL"}, "from": { "kind": "DockerImage", "name": "registry.redhat.io/rhscl/postgresql-10-rhel7"}, "name": "2.9", "referencePolicy": {"type": "Source"}}}]'Copy to Clipboard Copied! Toggle word wrap Toggle overflow このパッチにより
system-postgresqlイメージストリームが更新され、2.9 タグが含まれるようになります。以下のコマンドにより Tags 欄に 2.9 が表示されれば、タグが作成されていることを確認することができます。oc get is system-postgresql
oc get is system-postgresqlCopy to Clipboard Copied! Toggle word wrap Toggle overflow system-postgresqlImageChange トリガーにパッチを適用します。最新のトリガーを削除します。
oc set triggers dc/system-postgresql --from-image=system-postgresql:latest --containers=system-postgresql --remove
oc set triggers dc/system-postgresql --from-image=system-postgresql:latest --containers=system-postgresql --removeCopy to Clipboard Copied! Toggle word wrap Toggle overflow 新しいバージョン固有のトリガーを追加します。
oc set triggers dc/system-postgresql --from-image=system-postgresql:2.9 --containers=system-postgresql
oc set triggers dc/system-postgresql --from-image=system-postgresql:2.9 --containers=system-postgresqlCopy to Clipboard Copied! Toggle word wrap Toggle overflow イメージに新しい更新があれば、このパッチがトリガーとなり
system-postgresqlDeploymentConfig も再デプロイされます。その場合は、新規 Pod の再デプロイが完了して使用できる状態になり、古い Pod が終了するまで待ちます。ImageStreamから:latestタグを削除します。oc tag -d system-postgresql:latest
oc tag -d system-postgresql:latestCopy to Clipboard Copied! Toggle word wrap Toggle overflow