pod的yaml如下:这里使用的是主机host模式
apiVersion: apps/v1
kind: Deployment
metadata:name: jaegerlabels:app: jaeger
spec:replicas: 1selector:matchLabels:app: jaegertemplate:metadata:labels:app: jaegerspec:hostNetwork: truecontainers:- name: jaegerimage: docker.io/rancher/mirrored-jaegertracing-all-in-one:1.56.0ports:- containerPort: 5775protocol: UDP- containerPort: 6831protocol: UDP- containerPort: 6832protocol: UDP- containerPort: 5778protocol: TCP- containerPort: 16686protocol: TCP- containerPort: 14268protocol: TCP- containerPort: 14250protocol: TCP- containerPort: 9411protocol: TCPenv:- name: COLLECTOR_ZIPKIN_HOST_PORTvalue: ":9411"
可以通过:
kubectl get pod -o wide
看到pod的ip就是节点的ip。
在主机浏览器通过:
http://192.168.153.32:16686 访问