apiVersion: apps/v1
kind: Deployment
metadata:
  name: vault-secrets-operator
  namespace: vault-secrets-operator
  labels:
    app: vault-secrets-operator
spec:
  selector:
    matchLabels:
      app: vault-secrets-operator
  replicas: 1
  template:
    metadata:
      labels:
        app: vault-secrets-operator
    spec:
      serviceAccountName: vault-secrets-operator
      containers:
      - command:
        - /manager
        args:
        - --enable-leader-election
        image: ricoberger/vault-secrets-operator:1.11.0
        name: manager
        env:
        - name: WATCH_NAMESPACE
          value: ""
        - name: VAULT_ADDRESS
          value: "http://vault.vault.svc.cluster.local:8200"
        - name: VAULT_AUTH_METHOD
          value: "token"
        - name: VAULT_TOKEN
          value: ""
        - name: VAULT_TOKEN_LEASE_DURATION
          value: "86400"
        - name: VAULT_RECONCILIATION_TIME
          value: "0"
        ports:
        - name: metrics
          containerPort: 8080
          protocol: TCP
        - name: http
          containerPort: 8081
          protocol: TCP
        livenessProbe:
          httpGet:
            path: /healthz
            port: http
        readinessProbe:
          httpGet:
            path: /readyz
            port: http
        resources:
          limits:
            cpu: 100m
            memory: 30Mi
          requests:
            cpu: 100m
            memory: 20Mi
