Member-only story

Running Kafka MQ Source Connector in OpenShift

Zhimin Wen
5 min readJul 13, 2020

--

The Event Streams of IBM Cloud Pak for Integration provides most of the building components for the Kafka Connectors. This paper documents the complete steps for running a Kafka MQ source connector in the OpenShift cluster.

1. Configure Source MQ

The source MQ is running inside the OpenShift cluster. As Kafka connector needs to connect to the MQ, authorization and authentication are required. Assume we are using OS-based user authentication, the MQ container image running in the cluster needs to have the users and authentication defined.

Let’s create the following Dockerfile. Use the source container image from the IBM container registry as the base image, change user to root to add a new user and set the password, finally switch back to the default MQ user.

FROM cp.icr.io/cp/icp4i/mq/ibm-mqadvanced-server-integration:9.1.4.0-r1-amd64USER root
RUN useradd mqclient -G mqm \
&& echo mqclient:password | chpasswd
USER mqm

Build the image and push the image into OpenShift private registry with toolbuildah

buildah build-using-dockerfile --creds=cp:{{ .token }} -f ./Dockerfile -t {{ .tag }} .buildah push --tls-verify=false --creds=anyone:$(oc whoami…

--

--

No responses yet