Skip to main content
Version: v3.9.0

Diagnostic service

Goal​

Create kind: Service for diagnostic-service. The microservice is already deployed in production monitoring. It listens on external port 8081 and does not use NATS.

The dashboard on ops-b calls this bridge. The next page copies bridgePort into DIAGNOSTIC_URL.

The file is deploy/steps/05-service-diagnostic.yaml.

YAML​

diagnostic-service
apiVersion: datasance.com/v3
kind: Service
metadata:
name: diagnostic-service
tags:
- pot-edge-patterns
spec:
type: microservice
resource: production-monitoring/diagnostic-service
targetPort: 8081
defaultBridge: default-router
FieldValue
resourceproduction-monitoring/diagnostic-service
targetPort8081 (Edgelet external port, not container port 8080)
defaultBridgedefault-router
tagspot-edge-patterns

Tag ops-b with service.iofog.org/tag: pot-edge-patterns so that node opens the listener. See Distribution tags.

Deploy​

potctl deploy -f deploy/steps/05-service-diagnostic.yaml

What you should see​

potctl describe service diagnostic-service

The output includes bridgePort. Copy it on the next page. resource is production-monitoring/diagnostic-service.

Common mistakes​

The Service is created before diagnostic-service is deployed.

targetPort is 8080. Use 8081.

ops-b has no pot-edge-patterns tag, so the dashboard call times out.

Next​

Diagnostic bridge port

Group 3See anything wrong with the document? Help us improve it!