apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: kafka
    component: zookeeper
  name: zookeeper
spec:
  replicas: 1
  selector:
    matchLabels:
      app: kafka
      component: zookeeper
  template:
    metadata:
      labels:
        app: kafka
        component: zookeeper
    spec:
      containers:
      - name: zookeeper
        image: zookeeper:3.6.2
        ports:
        - containerPort: 2181
        env:
        - name: ZOOKEEPER_ID
          value: "1"
        - name: ZOOKEEPER_SERVER_1
          value: zookeeper
