apiVersion: v1
kind: Pod
metadata:
  name: step2-pod
  labels:
    stepName: step2
spec:
  containers:
      - name: sidecar
        image: sidecar:latest
        imagePullPolicy: Never
        resources:
          limits:
            memory: "128Mi"
            cpu: "500m"
        env:
          - name: ASPNETCORE_URLS
            value: http://+:5000
          - name: NODE_IP
            valueFrom:
              fieldRef: 
                fieldPath: status.hostIP
        ports:
          - containerPort: 5000
            protocol: TCP


      - name: compute
        image: compute:latest
        imagePullPolicy: Never
        resources:
          limits:
            memory: "128Mi"
            cpu: "500m"
        env:
          - name: ASPNETCORE_URLS
            value: http://localhost:5002
          - name: POD_NAME
            valueFrom:
              fieldRef:
                fieldPath: metadata.name
          - name: NODE_IP
            valueFrom:
              fieldRef: 
                fieldPath: status.hostIP
        volumeMounts:
          - mountPath: /in
            name: inputs
          - mountPath: /out
            name: outputs
  volumes:
      - name: inputs
        hostPath:
          path: /store/inputs
      
      - name: outputs
        hostPath:
          path: /store/outputs

