apiVersion: apps/v1
kind: Deployment
metadata:
  name: ixcloud-deployment
  labels:
    app: ixcloudapp
  #namespace: ixcloud
spec:
  replicas: 2
  selector:
    matchLabels:
      app: ixcloudapp
  template:
    metadata:
      labels:
        app: ixcloudapp
    spec:
      containers:
      - image: xxxxx.dkr.ecr.eu-west-1.amazonaws.com/ixcloud:latest
        name: ixcloudapp
        imagePullPolicy: Always
        command: ["/opt/intrexx/bin/linux/portal.sh"]
        args: ["/opt/intrexx/org/cloud"]
        resources:
          limits:
            cpu:  1
            memory: 2048Mi
          requests:
            cpu:    1
            memory:   1024Mi
        volumeMounts:
        - mountPath: /opt/intrexx/org/cloud
          name: ixcloudapp-volume
        - mountPath: /opt/intrexx/bin
          name: ixcloudapp-volume-bin
        - mountPath: /opt/intrexx/cfg
          name: ixcloudapp-volume-cfg
      volumes:
      - name: ixcloudapp-volume
        nfs:
          server: fs-xxxxx.efs.eu-west-1.amazonaws.com
          path: /share/cloud
      - name: ixcloudapp-volume-bin
        nfs:
          server: fs-xxxxx.efs.eu-west-1.amazonaws.com
          path: /share/bin
      - name: ixcloudapp-volume-cfg
        nfs:
          server: fs-xxxxx.efs.eu-west-1.amazonaws.com
          path: /share/cfg
