k8s hostpath 服务暴露
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: ip
labels:
app: ip
spec:
template:
metadata:
name: ip
labels:
app: ip
spec:
containers:
- name: ip
image: ip:latest
imagePullPolicy: Always
ports:
- containerPort: 8080
hostPort: 31187
name: ip
protocol: TCP
imagePullSecrets:
- name: tencent-registry
restartPolicy: Always
selector:
matchLabels:
app: ip