Setting Up BWCE Application Monitoring on Kubernetes
The following steps describe how to set up TIBCO BusinessWorks Container Edition application on Kubernetes.
Prerequisites
Procedure
- Extract the bwce_mon-<version>.zip file.
-
Navigate to the
bwce_mon directory and build the docker image by running the following command.
docker build -t bwce/monitoring:latest.
-
Tag the monitoring application image by running the following command:
docker tag <monitoring_application_name> your_docker_container_registry/<your_project_name>/ <monitoring_application_name>
-
Push your monitoring application image to the Docker Container Registry. For example, to push your monitoring application docker image on Google Cloud Registry, run the following command:
gcloud docker push gcr.io/<your_project_name>/<monitoring_application_name>
- Confirm that the image is present in the Docker Container Registry.
-
Create the
manifest.yml file and update the monitoring application image name. Ensure that the image name follows the following format:
<your_docker_container_registry>/<your_gcloud_project_name>/<monitoring_application_image_name>
-
To configure monitoring application with external database, add the following two environment variables to the
manifest.yml file.
The below is of a sample manifest.yml file:
apiVersion: v1 kind: Service metadata: name: monpg labels: app: monpg spec: type: LoadBalancer ports: - port: 80 targetPort: 8080 selector: app: monpg --- apiVersion: v1 kind: ReplicationController metadata: name: monpg spec: replicas: 1 selector: app: monpg template: metadata: name: monpg labels: app: monpg spec: containers: - name: monpg image: gcr.io/bwce-187719/monpg resources: limits: memory: 512Mi requests: memory: 512Mi imagePullPolicy: Always env: - name: PERSISTENCE_TYPE value:postgres - name: DB_URL value: postgres://bwuser:password@13.56.67.132:5432/postgres ports: - containerPort: 8080
- To create the monitoring service and replication controller, run the following command:
-
To verify that the monitoring application has started successfully, run the following command:
kubectl logs pod-name
-
To get the external IP of running monitoring service, run the following command:
kubectl get svc
Access the monitoring dashboard in the browser by using the external IP.
Copyright © Cloud Software Group, Inc. All rights reserved.