apiVersion: apps/v1
kind: Deployment
metadata:
  name: message-service-daemon-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      component: message-service-daemon
  template:
    metadata:
      labels:
        component: message-service-daemon
    spec:
      containers:
        - name: message-service-daemon
          image: metalom/message-service:latest
          imagePullPolicy: IfNotPresent
          command: ["/usr/bin/supervisord"]
          env:
            - name: APP_ENV
              value: 'prod'
            - name: MESSENGER_TRANSPORT_DSN
              value: 'amqp://rabbitmq:secret@rabbitmq-message-cluster-ip:5672/%2f'
            - name: DATABASE_URL
              value: 'mysql://user:secret@message-service-mysql-cluster-ip:3306/message_service?serverVersion=8.0'
