apiVersion: apps/v1
kind: Deployment
metadata:
  name: php-my-admin
  labels:
    app: php-my-admin
spec:
  # replicas: 2
  selector:
    matchLabels:
      app: php-my-admin
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        app: php-my-admin
    spec:
      containers:
      - image: php_my_admin_alpine
        name: php-my-admin
        imagePullPolicy: Never
        livenessProbe:
          exec:
            command:
            - /bin/ash
            - -c
            - 'pgrep telegraf'
        ports:
        - containerPort: 80
          name: php-my-admin
        livenessProbe:
          exec:
            command:
              - /bin/ash
              - -c
              - 'pgrep telegraf'
          initialDelaySeconds: 10
          periodSeconds: 5
