Search This Blog

Tuesday, January 30, 2024

IBM MAS - Getting the Manage admin Docker image

 Getting the Manage admin Docker image:

Prerequisites for this activity. Use the following steps to install Docker.

1.       Install Docker from https://docs.docker.com.

2.       Make sure that the docker daemon is running.

Procedure

1)         In your Linux® terminal, run the oc login command.

$ oc login --token=sha256~yLcd9N_ih1UX7tGcq9REywmoliEGvK4R-rtDu_xxxxx --server=https://api.mas-app-sb123.cp.fyre.ibm.com:6443

2)      Expose the internal registry to external using Route.

$ oc patch configs.imageregistry.operator.openshift.io/cluster --patch '{"spec":{"defaultRoute":true}}' --type=merge

3)      Verify the internal registry route hostname.

$ oc get route -n openshift-image-registry

NAME            HOST/PORT         PATH  SERVICES        PORT      TERMINATION      WILDCARD

default-route   default-route-openshift-image-registry.apps.mas-app-sb1.cp.fyre.ibm.com         image-registry  all       reencrypt        None

image-registry  image-registry.openshift-image-registry.svc        image-registry  5000-tcp  reencrypt        None

4)      Log in by using the default registry route hostname.

docker login -u <user_name> -p $(oc whoami -t) default-route-openshift-image-registry.apps.<clustername>.<basedomain>

$ sudo docker login -u kubeadmin -p $(oc whoami -t) https://default-route-openshift-image-registry.apps.mas-app-sb123.cp.fyre.ibm.com

Remember: If you get x509: certificate signed by unknown authority error message, then you must place the Router trusted CA on your host.

5)      Extract the CA from Red Hat® OpenShift® Container Platform cluster, where the registry is configured.

$ oc extract secret/router-ca --keys=tls.crt -n openshift-ingress-operator

6)      Perform on the node, where the image pulling throws x509 error.

$ sudo cp tls.crt /usr/local/share/ca-certificates/.

$ sudo update-ca-certificates

7)      Make sure that the docker daemon is running.

$ ps -aux | grep dockerd

root       203  0.0  0.0  10508  4232 pts/0    T    01:28   0:00 sudo dockerd

root      2397  0.0  0.0  11016  4612 pts/1    S    16:49   0:00 sudo dockerd

root      2398  0.0  0.4 1538160 111260 pts/1  Sl   16:49   0:07 dockerd

sarika    3999  0.0  0.0   8160   724 pts/1    S+   23:26   0:00 grep --color=auto dockerd

 8)      Pull admin docker latest image: docker pull <Public image Repository> From the Manage project in OpenShift console, get the Public Image Repository value from the <instanceid>-<workspaceid>-admin in ImageStreams under Builds.

$ sudo docker pull `default-route-openshift-image-registry.apps.mas-app-sb1.cp.fyre.ibm.com/mas-sb1-manage/sb1-masdev-admin`

 9)      Get Image ID: docker images

$ sudo docker images

REPOSITORY                                       TAG      IMAGE ID      CREATED      SIZE

default-route-openshift-image-registry.apps.mas-app-sb1.cp.fyre.ibm.com/mas-sb1-manage/sb1-masdev-admin  latest   c0e655398e6b  3 weeks ago  7.87GB

 10)   Run the docker pulled admin image docker run -d <image id>.

$ sudo docker run -d c0e655398e6b

1f2dfad8d3c813792798dc1f220bf27b7935f604c4817f47346a1f96e2336a92

time="2021-06-26T16:54:46.067182200-04:00" level=info msg="starting signal loop" namespace=moby path=/run/docker/containerd/daemon/io.containerd.runtime.v2.task/moby/1f2dfad8d3c813792798dc1f220bf27b7935f604c4817f47346a1f96e2336a92 pid=2832

 11)   Get the container ID for the pulled admin image. docker ps -a

$ sudo docker images

REPOSITORY                  TAG      IMAGE ID      CREATED      SIZE

default-route-openshift-image-registry.apps.mas-app-sb1.cp.fyre.ibm.com/mas-sb1-manage/sb1-masdev-admin  latest   c0e655398e6b  3 weeks ago  7.87GB

12)   Copy the Manage code locally.

$ sudo docker cp d3544a11901e:/opt/IBM/SMP/maximo/latest.zip /mnt/c/temp/.

13)   Optional: Run tools such as integrity checker.

docker exec -it <container id> /bin/bash

Update the Maximo properties in /opt/IBM/SMP/maxio/applications/maximo/propertiesfolder.

Execute /opt/IBM/SMP/maxio/applications/maximo/validate_integ.sh.

Reference Link : https://www.ibm.com/docs/en/mas-cd/continuous-delivery?topic=preparing-getting-manage-admin-docker-image

No comments:

Post a Comment

MAS and Manage custom resources are not reconciled

  After a change was applied to IBM Maximo Application Suite (MAS) or IBM Maximo Manage, the custom resources are not reconciled. For exampl...