📋 Prerequisites

  • An active domain on OnlyDNS.
  • A TSIG Key generated in the OnlyDNS Portal or via CLI (onlydns tsig create --algo hmac-sha256).
  • A Kubernetes cluster with cert-manager installed (v1.10+).
1

Create Kubernetes Secret for TSIG Key

Create a Kubernetes Secret inside the cert-manager namespace to securely store your OnlyDNS base64 TSIG secret:

kubectl create secret generic onlydns-tsig-secret \
  --namespace=cert-manager \
  --from-literal=tsig-secret="YOUR_BASE64_TSIG_SECRET_KEY"
2

Create ClusterIssuer Resource

Define a cluster-wide ClusterIssuer referencing OnlyDNS primary nameserver and the TSIG secret:

cluster-issuer.yaml
apiVersion: cert-manager.io/v1
kind: ClusterIssuer
metadata:
  name: letsencrypt-onlydns-rfc2136
spec:
  acme:
    email: admin@example.com
    server: https://acme-v02.api.letsencrypt.org/directory
    privateKeySecretRef:
      name: letsencrypt-account-private-key
    solvers:
    - dns01:
        rfc2136:
          nameserver: ns1.onlydns.com:53
          tsigKeyName: your-tsig-key-name
          tsigAlgorithm: HMACSHA256
          tsigSecretSecretRef:
            name: onlydns-tsig-secret
            key: tsig-secret
kubectl apply -f cluster-issuer.yaml
🔒 Least-Privilege Security Tip: In the OnlyDNS Portal or REST API, restrict this TSIG key to only update the _acme_challenge subdomain so cert-manager in Kubernetes cannot modify other DNS records.
3

Request Wildcard Certificate on Ingress

Attach the cluster issuer annotation to any Kubernetes Ingress (Nginx Ingress, Traefik, Cilium, etc.) or create a standalone Certificate resource:

ingress-wildcard.yaml
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: web-ingress
  namespace: default
  annotations:
    cert-manager.io/cluster-issuer: letsencrypt-onlydns-rfc2136
spec:
  ingressClassName: nginx
  tls:
  - hosts:
    - "example.com"
    - "*.example.com"
    secretName: example-com-tls
  rules:
  - host: "app.example.com"
    http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          service:
            name: app-service
            port:
              number: 80
kubectl apply -f ingress-wildcard.yaml
kubectl get certificate -w

Message Sent

Thanks for contacting OnlyDNS. We received your message and will follow up shortly.