Deploy custom Kubernetes compliant Zookeeper image (extended from Kubernetes Zookeepper) with added features:
- Publish json formatted logs for easy consumption by EFK stack
This image can be run in any container platform
- Refer the custom jar in extra_lib. This will format logs into Json format.
- Modified Log4j properties are in conf
- bin\start-zookeeper is modified to not use the existing log4j properties file
- Build image:
docker build -t anair/zookeeper:3.4.10-1 .
- Create new project in minishift
- Deploy k8s/zookeeper-sts.yaml stateful set to create a 3 pod zookeeper cluster
- Verify logs are in json format
- Build image:
docker build -t anair/zookeeper:3.4.10-1 .
- Decide on the namespace where zookeeper should be deployed. The project uses anair-zk as the namespace.
- Tag image Openshift registry naming convention
- Push image to Openshift registry. The image will appear in ImageStreams of the namespace
- Open ZK statefulset a. Review and change parameters as required b. Update namespace c.Update the image name with Openshift registry image name
- Deploy the statefuleset
- Verify json formatted logs