apiVersion: apps/v1
kind: Deployment
metadata:
  name: web
spec:
  selector:
    matchLabels:
      name: web
      tier: frontend
  replicas: 2
  template:
    metadata:
      labels:
        name: web
        tier: frontend
    spec:
      containers:
      - name: ping
        image: "kumsub/pingservice"
        ports:
        - name: tcp
          containerPort: 8090
        env:
        - name: SERVER_PORT
          value: "8090"
        - name: CACHE_TYPE
          value: redis
        - name: CACHE_HOST
          value: cache
        - name: CACHE_PORT
          value: "6379"
      - name: cache
        image: "redis"
        ports:
        - name: tcpredis
          containerPort: 6379