cw-agent-certmanager

by gnana997

Helm chartv0.5.5App 0.5.5Apache-2.0Verified publisher

CertWatch Agent for cert-manager - Monitors Kubernetes certificates managed by cert-manager

About this chart

CertWatch Agent for cert-manager

Helm chart for deploying the CertWatch cert-manager controller. This agent monitors certificates managed by cert-manager in your Kubernetes cluster and syncs them to CertWatch.

Tip: For deploying multiple CertWatch agents, consider using the cw-stack umbrella chart.

Prerequisites

  • Kubernetes 1.19+
  • Helm 3.8+
  • cert-manager installed in your cluster
  • CertWatch account and API key

Installation

Quick Start

helm install cw-agent-certmanager oci://ghcr.io/certwatch-app/helm-charts/cw-agent-certmanager \
  --namespace certwatch --create-namespace \
  --set agent.name=my-cluster \
  --set apiKey.value=cw_your_api_key

Using an Existing Secret (Recommended for Production)

# Create the secret first
kubectl create namespace certwatch
kubectl create secret generic cw-api-key \
  --namespace certwatch \
  --from-literal=api-key=cw_your_api_key

# Install the chart
helm install cw-agent-certmanager oci://ghcr.io/certwatch-app/helm-charts/cw-agent-certmanager \
  --namespace certwatch \
  --set agent.name=my-cluster \
  --set apiKey.existingSecret.name=cw-api-key

Configuration

Required Values

ParameterDescription
agent.nameUnique name identifying this agent in CertWatch
apiKey.value OR apiKey.existingSecret.nameCertWatch API key

Key Configuration Options

ParameterDescriptionDefault
agent.nameAgent name (required)""
agent.logLevelLog level: debug, info, warn, error"info"
agent.syncIntervalHow often to sync certificates"30s"
agent.heartbeatIntervalHeartbeat interval for offline alerts"30s"
agent.watchAllNamespacesWatch all namespacestrue
agent.namespacesSpecific namespaces to watch[]
agent.metricsPortPrometheus metrics port (0 to disable)9402
agent.healthPortHealth probe port9403

API Configuration

ParameterDescriptionDefault
api.endpointCertWatch API endpoint"https://api.certwatch.app"
api.timeoutAPI request timeout"30s"
apiKey.valueAPI key (creates a Secret)""
apiKey.existingSecret.nameName of existing Secret""
apiKey.existingSecret.keyKey in the Secret"api-key"

Resources & Security

ParameterDescriptionDefault
resources.requests.cpuCPU request"10m"
resources.requests.memoryMemory request"64Mi"
resources.limits.cpuCPU limit"100m"
resources.limits.memoryMemory limit"128Mi"
securityContext.runAsNonRootRun as non-roottrue
securityContext.readOnlyRootFilesystemRead-only filesystemtrue

Observability

ParameterDescriptionDefault
serviceMonitor.enabledCreate Prometheus ServiceMonitorfalse
serviceMonitor.intervalScrape interval"30s"
podDisruptionBudget.enabledCreate PodDisruptionBudgetfalse

Example Values File

agent:
  name: production-cluster
  logLevel: info
  watchAllNamespaces: true

apiKey:
  existingSecret:
    name: cw-api-key

resources:
  requests:
    cpu: 10m
    memory: 64Mi
  limits:
    cpu: 100m
    memory: 128Mi

serviceMonitor:
  enabled: true
  interval: 30s

podDisruptionBudget:
  enabled: true
  minAvailable: 1

RBAC

This chart creates a ClusterRole with permissions to:

  • Read cert-manager resources: certificates, certificaterequests, issuers, clusterissuers
  • Read core resources: secrets (certificate data), events, namespaces

Upgrading

helm upgrade cw-agent-certmanager oci://ghcr.io/certwatch-app/helm-charts/cw-agent-certmanager \
  --namespace certwatch \
  --reuse-values

Uninstalling

helm uninstall cw-agent-certmanager --namespace certwatch

Note: The API key Secret has helm.sh/resource-policy: keep and will not be deleted automatically.

Troubleshooting

View Logs

kubectl logs -n certwatch -l app.kubernetes.io/name=cw-agent-certmanager -f

Check Agent Status

kubectl get pods -n certwatch -l app.kubernetes.io/name=cw-agent-certmanager

Verify RBAC

kubectl auth can-i list certificates.cert-manager.io \
  --as=system:serviceaccount:certwatch:cw-agent-certmanager

Related Charts

  • cw-agent - Network certificate scanner
  • cw-stack - Umbrella chart for deploying both agents

Documentation

License

Apache 2.0

Deploy cw-agent-certmanager with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has cw-agent-certmanager on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartcw-agent-certmanager is pinned at v0.5.5 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply