apiVersion: apps/v1
kind: Deployment
metadata:
  name: mariadb-dep
spec:
  replicas: 1
  selector:
    matchLabels:
      app: mariadb
  template:
    metadata:
      labels:
        app: mariadb
    spec:
      containers:
      - name: app
        image: mariadb
        env:
        - name: MYSQL_ROOT_PASSWORD
          value: "mypassword"
        - name: MYSQL_DATABASE
          value: "demo"
        ports:
        - name: db
          containerPort: 3306
