apiVersion: apps/v1
kind: Deployment
metadata:
  name: currencyexchange
  labels:
    app: currencyexchange
    version: v1
spec:
  replicas: 1
  selector:
    matchLabels:
      app: currencyexchange
      version: v1
  strategy:
    rollingUpdate:
      maxSurge: 25%
      maxUnavailable: 25%
    type: RollingUpdate
  template:
    metadata:
      labels:
        app: currencyexchange
        version: v1
    spec:
      containers:
      - image: beetravels/currencyexchange:node-v1.0.2
        imagePullPolicy: Always
        name: currencyexchange
        env:
          - name: PORT
            value: "9201"
          - name: HOST_IP
            value: currencyexchange
          - name: SCHEME
            value: http
        resources:
          limits:
            cpu: 200m
            memory: 256Mi
          requests:
            cpu: 200m
            memory: 256Mi
      restartPolicy: Always