Richard Jankowski | d7921b7 | 2018-02-20 16:55:12 -0500 | [diff] [blame] | 1 | apiVersion: v1 |
| 2 | kind: Service |
| 3 | metadata: |
| 4 | name: kafka |
| 5 | namespace: voltha |
| 6 | spec: |
| 7 | clusterIP: None |
| 8 | selector: |
| 9 | app: kafka |
| 10 | ports: |
| 11 | - protocol: TCP |
| 12 | port: 9092 |
| 13 | targetPort: 9092 |
| 14 | --- |
| 15 | apiVersion: apps/v1beta1 |
| 16 | kind: StatefulSet |
| 17 | metadata: |
| 18 | name: kafka |
| 19 | namespace: voltha |
| 20 | spec: |
| 21 | serviceName: kafka |
| 22 | replicas: 1 |
| 23 | selector: |
| 24 | matchLabels: |
| 25 | app: kafka |
| 26 | template: |
| 27 | metadata: |
| 28 | labels: |
| 29 | app: kafka |
| 30 | annotations: |
Stephane Barbarie | 2d4e07f | 2018-03-26 16:46:45 -0400 | [diff] [blame] | 31 | cni: "calico" |
Richard Jankowski | d7921b7 | 2018-02-20 16:55:12 -0500 | [diff] [blame] | 32 | spec: |
| 33 | terminationGracePeriodSeconds: 10 |
| 34 | containers: |
| 35 | - name: kafka |
| 36 | image: wurstmeister/kafka:1.0.0 |
| 37 | ports: |
| 38 | - containerPort: 9092 |
| 39 | env: |
| 40 | - name: KAFKA_ADVERTISED_PORT |
| 41 | value: "9092" |
| 42 | - name: KAFKA_ZOOKEEPER_CONNECT |
| 43 | value: zoo:2181 |
| 44 | - name: KAFKA_HEAP_OPTS |
| 45 | value: "-Xmx256M -Xms128M" |