apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: zookeeper
  name: zookeeper-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      app: zookeeper
  template:
    metadata:
      labels:
        app: zookeeper
    spec:
      containers:
      - image: digitalwonderland/zookeeper:latest
        name: zookeeper
        ports:
        - containerPort: 2181
        - containerPort: 2888
        - containerPort: 3888
        livenessProbe:
          tcpSocket:
            port: 2181
          initialDelaySeconds: 10
          periodSeconds: 10
        readinessProbe:
          tcpSocket:
            port: 2181
          initialDelaySeconds: 20
          periodSeconds: 20
      restartPolicy: Always
