apiVersion: apps/v1 # for versions before 1.9.0 use apps/v1beta2
kind: Deployment
metadata:
  name: cassandra-test
spec:
  selector:
    matchLabels:
      app: cassandra-test
  replicas: 1 # tells deployment to run 2 pods matching the template
  template: # create pods using pod definition in this template
    metadata:
      # unlike pod-nginx.yaml, the name is not included in the meta data as a unique name is
      # generated from the deployment name
      labels:
        app: cassandra-test
    spec:
      containers:
      - name: cassandra-test
        image: soerenhenning/cassandra-test:d1805241407
        env:
        - name: CASSANDRA_HOST
          value: "cassandra.titan-ccp.svc.cluster.local"
        - name: WEBSERVER_PORT
          value: "80"
        - name: KAFKA_BOOTSTRAP_SERVERS
          value: "bootstrap:9092"
