apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: zhios
  name: zhios-mall
  labels:
    app: zhios-mall
spec:
  replicas: 1
  template:
    metadata:
      name: zhios-mall
      labels:
        app: zhios-mall
    spec:
      containers:
        - name: zhios-mall-container
          image: registry-vpc.cn-shenzhen.aliyuncs.com/fnuoos-prd/zyos-mall:0.1
          ports:
            - containerPort: 5002
              name: 5002tcp
              protocol: TCP
          resources:
            limits:
              cpu: "1"
              memory: 256Mi
            requests:
              cpu: 200m
              memory: 128Mi
          imagePullPolicy: IfNotPresent
      restartPolicy: Always
      volumes:
        - name: host-time
          hostPath:
            path: /etc/localtime
            type: ''
        - name: mall-cfg
          configMap:
            name: zhios-mall-cfg
            defaultMode: 420
  selector:
    matchLabels:
      app: zhios-mall

  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxUnavailable: 25%
      maxSurge: 25%
