apiVersion: apps/v1
kind: Deployment
metadata:
  name: mail-sender-server
spec:
  selector:
    matchLabels:
      app: mail-sender
  template:
    metadata:
      labels:
        app: mail-sender
    spec:
      containers:
      - name: sender-server
        image: tmaxcloudck/mail-sender-server:v0.0.3
        imagePullPolicy: Always
        env:
        - name: SMTP_SERVER
          valueFrom:
            secretKeyRef:
              name: mail-sender-cfg
              key: smtpServer
        - name: SMTP_USER_NAME
          valueFrom:
            secretKeyRef:
              name: mail-sender-cfg
              key: smtpUserId
        - name: SMTP_PASSWORD
          valueFrom:
            secretKeyRef:
              name: mail-sender-cfg
              key: smtpUserPw
        resources:
          requests:
            cpu: 50m
            memory: 50Mi
          limits:
            cpu: 100m
            memory: 100Mi
