---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: catalogue-db
  labels:
    name: catalogue-db
    tags.datadoghq.com/env: "production"
    tags.datadoghq.com/service: "catalogue-db"
    tags.datadoghq.com/version: "v1"
  namespace: sock-shop
spec:
  replicas: 1
  selector:
    matchLabels:
      name: catalogue-db
  template:
    metadata:
      labels:
        name: catalogue-db
        tags.datadoghq.com/env: "production"
        tags.datadoghq.com/service: "catalogue-db"
        tags.datadoghq.com/version: "v1"
      annotations:
        ad.datadoghq.com/catalogue-db.check_names: '["mysql"]'
        ad.datadoghq.com/catalogue-db.init_configs: '[{}]'
        ad.datadoghq.com/catalogue-db.instances: '[{"server": "%%host%%", "user": "datadog","pass": "datadogmetrics"}]'
    spec:
      containers:
      - name: catalogue-db
        image: catalogue-db
        env:
          - name: MYSQL_ROOT_PASSWORD
            value: fake_password
          - name: MYSQL_DATABASE
            value: socksdb
        ports:
        - name: mysql
          containerPort: 3306
      nodeSelector:
        beta.kubernetes.io/os: linux
