apiVersion: apps/v1
kind: Deployment
metadata:
  name: message-service-nginx-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      component: message-service-nginx
  template:
    metadata:
      labels:
        component: message-service-nginx
    spec:
      containers:
        - name: message-service-nginx
          image: nginx:1.15.0
          ports:
            - containerPort: 80
          volumeMounts:
            - name: config-volume
              mountPath: /etc/nginx/conf.d/
      volumes:
        - name: config-volume
          configMap:
            name: message-service-nginx-config
