Rate This Document
Findability
Accuracy
Completeness
Readability

Configuring the Local Repository and Image

Perform operations in this section on physical nodes.

  1. Pull the local repository registry:2.
    podman pull docker.io/library/registry:2
    If you cannot access the external network, run the following commands or manually download the package and import it to the current node.
    git config --global http.sslVerify false
    git config --global https.sslVerify false
    git clone https://github.com/NotGlop/docker-drag.git
  2. Start the local repository.
    podman load -i registry_2.tar
  3. Modify the container configuration file /etc/containers/registries.conf.
    unqualified-search-registries = ["[IP]", "quay.io"]
    short-name-mode="enforcing"
    [[registry]]
    location = "[IP]:5000"
    insecure = true

    [IP] indicates the actual local IP address.

  4. Modify the local repository settings.
    mkdir -p /home/registry-data
    podman run -d -p 5000:5000 -v /home/registry-data:/var/lib/registry --restart always --name registry localhost/registry:2
  5. Import the Ceph deployment image generated in Creating a Deployment Image.
    podman load -i ceph_release.tar
  6. Rename the image and upload it to the local repository.
    podman tag 8bbba7d5cc80 [IP]:5000/ceph/ceph_release:v17.2.7
    podman push [IP]:5000/ceph/ceph_release:v17.2.7 [IP]:5000/ceph/ceph_release:v17.2.7
    • 8bbba7d5cc80 indicates the image ID corresponding to ceph_release.tar, and [IP] indicates the local IP address. Replace them with the actual values.
    • If the gateway timeout error is reported during the push, check whether any proxy is configured. If yes, disable the proxy.
      unset http_proxy
      unset https_proxy
  7. Modify DEFAULT_IMAGE in the cephadm file.
    vim /usr/sbin/cephadm
    yum install cephadm
    DEFAULT_IMAGE = "[IP]:5000/ceph/ceph_release:v17.2.7"
  8. Modify the container creation permission (run_cmd function) in cephadm as follows:
    if self.privileged --> if self.privileged or not self.privileged
    • /usr/sbin/cephadm can be installed by configuring the Ceph 17 source or directly copying cephadm in the source code.
    • [IP] indicates the actual local IP address.