---
apiVersion: v1
kind: Secret
metadata:
  name: cloudflare-api-token-secret
  namespace: cert-manager
type: Opaque
stringData:
  api-token: oXJRP5XI8Zhipa_PtYtB_jy6qWL0I9BosrJEYE8p

---
apiVersion: cert-manager.io/v1
kind: ClusterIssuer
metadata:
  name: cm-cloudflare-7421
spec:
  acme:
    privateKeySecretRef:
      name: cm-cloudflare-7421
    server: https://acme-v02.api.letsencrypt.org/directory
    solvers:
    - dns01:
        cloudflare:
          email: zeaslity@gmail.com # 替换成你的 cloudflare 邮箱账号，API Token 方式认证非必需，API Keys 认证是必需
          apiTokenSecretRef:
            name: cloudflare-api-token-secret
            key: api-token
      selector:
        dnsZones:
        - '107421.xyz'
---
apiVersion: cert-manager.io/v1
kind: Issuer
metadata:
  name: cm-cloudflare-7421
spec:
  acme:
    privateKeySecretRef:
      name: cm-cloudflare-7421
    server: https://acme-v02.api.letsencrypt.org/directory
    solvers:
      - dns01:
          cloudflare:
            email: zeaslity@gmail.com # 替换成你的 cloudflare 邮箱账号，API Token 方式认证非必需，API Keys 认证是必需
            apiTokenSecretRef:
              name: cloudflare-api-token-secret
              key: api-token
        selector:
          dnsZones:
            - '107421.xyz'