apiVersion: v1
kind: ReplicationController
metadata:
  name: calc-server-rc
  labels:
    app: calc-server
    version: v1
spec:
  replicas: 2
  template:
    metadata:
      labels:
        app: calc-server
        version: v1
    spec:
      containers:
      - name: calc-server-square
        image: taherbs/calcserver_calc_server_square:latest
        ports:
        - containerPort: 8080
        imagePullPolicy: Always
      - name: calc-server-add
        image: taherbs/calcserver_calc_server_add:latest
        ports:
        - containerPort: 8081
        imagePullPolicy: Always
        env:
          - name: "SQUAREHOST"
            value: "localhost"
          - name: "SQUAREPORT"
            value: "8080"
      - name: calc-server-srt
        image: taherbs/calcserver_calc_server_sqrt:latest
        ports:
        - containerPort: 8082
        env:
          - name: "ADDHOST"
            value: "localhost"
          - name: "ADDPORT"
            value: "8081"
        imagePullPolicy: Always
