apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: ui-for-docker
name: ui-for-docker
namespace: moonfdd
spec:
replicas: 1
selector:
matchLabels:
app: ui-for-docker
template:
metadata:
labels:
app: ui-for-docker
spec:
containers:
- image: uifd/ui-for-docker
imagePullPolicy: IfNotPresent
name: ui-for-docker
volumeMounts:
- mountPath: /var/run/docker.sock
name: volv
volumes:
- hostPath:
path: /var/run/docker.sock
type: Socket
name: volv
---
apiVersion: v1
kind: Service
metadata:
labels:
app: ui-for-docker
name: ui-for-docker
namespace: moonfdd
spec:
ports:
- port: 9000
protocol: TCP
targetPort: 9000
selector:
app: ui-for-docker
type: NodePort
评论