3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

OpenShift 4.4 Container Image Registry

Posted at

TL;DR

OpenShift 4.3 BaremetalインストールではOpenShift Image Registryのデフォルト値がRemovedになっており、自分で構成しなくては使えない状態になっているため、構成する方法を記載。

※4.2ではManagedだったためインストール後のタスクとして手順を踏まないとoc get clusteroperatorsの結果がAVAILABLE=Trueにならないので気づきやすかった

手順

ここではStorageClassにEnptyDirを使う。

  1. system:adminまたはそれに準ずるユーザでログインする
  2. image regesitryのストレージをemptyDirに変更する。
    oc patch configs.imageregistry.operator.openshift.io cluster --type merge --patch '{"spec":{"storage":{"emptyDir":{}}}}'
  3. config/clustermanagementStateを変更する
apiVersion: imageregistry.operator.openshift.io/v1
kind: Config
metadata:
[...]
spec:
  defaultRoute: false
  disableRedirect: false
  logging: 2
  managementState: Managed
[...]
  1. image-registry-operatorが変更を検知しimage registry Podが自動的に作成する
$ oc get pod -n openshift-image-registry
NAME                                              READY   STATUS    RESTARTS   AGE
cluster-image-registry-operator-d66bdbff7-b7rw5   2/2     Running   0          22d
image-registry-c9d4d966d-84nxs                    1/1     Running   0          13m
node-ca-7vhts                                     1/1     Running   0          13m
node-ca-8dlkm                                     1/1     Running   0          13m
node-ca-9tcnl                                     1/1     Running   0          13m
node-ca-b7jwb                                     1/1     Running   0          13m
node-ca-c7747                                     1/1     Running   0          13m
node-ca-kh8b6                                     1/1     Running   0          13m

Link

3
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?