cert-manager

by microfunctionsio

Helm chartv1.2.0App v1.2.0Verified publisher

A Helm chart for cert-manager

About this chart

cert-manager

cert-manager is a Kubernetes addon to automate the management and issuance of TLS certificates from various issuing sources.

It will ensure certificates are valid and up to date periodically, and attempt to renew certificates at an appropriate time before expiry.

Prerequisites

  • Kubernetes 1.11+

Installing the Chart

Full installation instructions, including details on how to configure extra functionality in cert-manager can be found in the installation docs.

Before installing the chart, you must first install the cert-manager CustomResourceDefinition resources. This is performed in a separate step to allow you to easily uninstall and reinstall cert-manager without deleting your installed custom resources.

$ kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.2.0/cert-manager.crds.yaml

To install the chart with the release name my-release:

## Add the Jetstack Helm repository
$ helm repo add jetstack https://charts.jetstack.io

## Install the cert-manager helm chart
$ helm install --name my-release --namespace cert-manager jetstack/cert-manager

In order to begin issuing certificates, you will need to set up a ClusterIssuer or Issuer resource (for example, by creating a 'letsencrypt-staging' issuer).

More information on the different types of issuers and how to configure them can be found in our documentation.

For information on how to configure cert-manager to automatically provision Certificates for Ingress resources, take a look at the Securing Ingresses documentation.

Tip: List all releases using helm list

Upgrading the Chart

Special considerations may be required when upgrading the Helm chart, and these are documented in our full upgrading guide.

Please check here before performing upgrades!

Uninstalling the Chart

To uninstall/delete the my-release deployment:

$ helm delete my-release

The command removes all the Kubernetes components associated with the chart and deletes the release.

If you want to completely uninstall cert-manager from your cluster, you will also need to delete the previously installed CustomResourceDefinition resources:

$ kubectl delete -f https://github.com/jetstack/cert-manager/releases/download/v1.2.0/cert-manager.crds.yaml

Configuration

The following table lists the configurable parameters of the cert-manager chart and their default values.

ParameterDescriptionDefault
global.imagePullSecretsReference to one or more secrets to be used when pulling images[]
global.rbac.createIf true, create and use RBAC resources (includes sub-charts)true
global.priorityClassNamePriority class name for cert-manager and webhook pods""
global.podSecurityPolicy.enabledIf true, create and use PodSecurityPolicy (includes sub-charts)false
global.podSecurityPolicy.useAppArmorIf true, use Apparmor seccomp profile in PSPtrue
global.leaderElection.namespaceOverride the namespace used to store the ConfigMap for leader electionkube-system
global.leaderElection.leaseDurationThe duration that non-leader candidates will wait after observing a leadership renewal until attempting to acquire leadership of a led but unrenewed leader slot. This is effectively the maximum duration that a leader can be stopped before it is replaced by another candidate
global.leaderElection.renewDeadlineThe interval between attempts by the acting master to renew a leadership slot before it stops leading. This must be less than or equal to the lease duration
global.leaderElection.retryPeriodThe duration the clients should wait between attempting acquisition and renewal of a leadership
installCRDsIf true, CRD resources will be installed as part of the Helm chart. If enabled, when uninstalling CRD resources will be deleted causing all installed custom resources to be DELETEDfalse
image.repositoryImage repositoryquay.io/jetstack/cert-manager-controller
image.tagImage tagv1.2.0
image.pullPolicyImage pull policyIfNotPresent
replicaCountNumber of cert-manager replicas1
clusterResourceNamespaceOverride the namespace used to store DNS provider credentials etc. for ClusterIssuer resourcesSame namespace as cert-manager pod
featureGatesComma-separated list of feature gates to enable on the controller pod``
extraArgsOptional flags for cert-manager[]
extraEnvOptional environment variables for cert-manager[]
serviceAccount.createIf true, create a new service accounttrue
serviceAccount.nameService account to be used. If not set and serviceAccount.create is true, a name is generated using the fullname template
serviceAccount.annotationsAnnotations to add to the service account
volumesOptional volumes for cert-manager[]
volumeMountsOptional volume mounts for cert-manager[]
resourcesCPU/memory resource requests/limits{}
securityContextOptional security context. The yaml block should adhere to the SecurityContext spec{}
securityContext.enabledDeprecated (use securityContext) - Enable security contextfalse
containerSecurityContextSecurity context to be set on the controller component container{}
nodeSelectorNode labels for pod assignment{}
affinityNode affinity for pod assignment{}
tolerationsNode tolerations for pod assignment[]
ingressShim.defaultIssuerNameOptional default issuer to use for ingress resources
ingressShim.defaultIssuerKindOptional default issuer kind to use for ingress resources
ingressShim.defaultIssuerGroupOptional default issuer group to use for ingress resources
prometheus.enabledEnable Prometheus monitoringtrue
prometheus.servicemonitor.enabledEnable Prometheus Operator ServiceMonitor monitoringfalse
prometheus.servicemonitor.namespaceDefine namespace where to deploy the ServiceMonitor resource(namespace where you are deploying)
prometheus.servicemonitor.prometheusInstancePrometheus Instance definitiondefault
prometheus.servicemonitor.targetPortPrometheus scrape port9402
prometheus.servicemonitor.pathPrometheus scrape path/metrics
prometheus.servicemonitor.intervalPrometheus scrape interval60s
prometheus.servicemonitor.labelsAdd custom labels to ServiceMonitor
prometheus.servicemonitor.scrapeTimeoutPrometheus scrape timeout30s
podAnnotationsAnnotations to add to the cert-manager pod{}
deploymentAnnotationsAnnotations to add to the cert-manager deployment{}
podDnsPolicyOptional cert-manager pod DNS policy
podDnsConfigOptional cert-manager pod DNS configurations
podLabelsLabels to add to the cert-manager pod{}
http_proxyValue of the HTTP_PROXY environment variable in the cert-manager pod
https_proxyValue of the HTTPS_PROXY environment variable in the cert-manager pod
no_proxyValue of the NO_PROXY environment variable in the cert-manager pod
webhook.replicaCountNumber of cert-manager webhook replicas1
webhook.timeoutSecondsSeconds the API server should wait the webhook to respond before treating the call as a failure.10
webhook.podAnnotationsAnnotations to add to the webhook pods{}
webhook.podLabelsLabels to add to the cert-manager webhook pod{}
webhook.deploymentAnnotationsAnnotations to add to the webhook deployment{}
webhook.mutatingWebhookConfigurationAnnotationsAnnotations to add to the mutating webhook configuration{}
webhook.validatingWebhookConfigurationAnnotationsAnnotations to add to the validating webhook configuration{}
webhook.extraArgsOptional flags for cert-manager webhook component[]
webhook.serviceAccount.createIf true, create a new service account for the webhook componenttrue
webhook.serviceAccount.nameService account for the webhook component to be used. If not set and webhook.serviceAccount.create is true, a name is generated using the fullname template
webhook.serviceAccount.annotationsAnnotations to add to the service account for the webhook component
webhook.resourcesCPU/memory resource requests/limits for the webhook pods{}
webhook.nodeSelectorNode labels for webhook pod assignment{}
webhook.affinityNode affinity for webhook pod assignment{}
webhook.tolerationsNode tolerations for webhook pod assignment[]
webhook.image.repositoryWebhook image repositoryquay.io/jetstack/cert-manager-webhook
webhook.image.tagWebhook image tagv1.2.0
webhook.image.pullPolicyWebhook image pull policyIfNotPresent
webhook.securePortThe port that the webhook should listen on for requests.10250
webhook.securityContextSecurity context for webhook pod assignment{}
webhook.containerSecurityContextSecurity context to be set on the webhook component container{}
webhook.hostNetworkIf true, run the Webhook on the host network.false
webhook.livenessProbe.failureThresholdThe livneness probe failure threshold3
webhook.livenessProbe.initialDelaySecondsThe livneness probe initial delay (in seconds)60
webhook.livenessProbe.periodSecondsThe livneness probe period (in seconds)10
webhook.livenessProbe.successThresholdThe livneness probe success threshold1
webhook.livenessProbe.timeoutSecondsThe livneness probe timeout (in seconds)1
webhook.readinessProbe.failureThresholdThe readiness probe failure threshold3
webhook.readinessProbe.initialDelaySecondsThe readiness probe initial delay (in seconds)5
webhook.readinessProbe.periodSecondsThe readiness probe period (in seconds)5
webhook.readinessProbe.successThresholdThe readiness probe success threshold1
webhook.readinessProbe.timeoutSecondsThe readiness probe timeout (in seconds)1
cainjector.enabledToggles whether the cainjector component should be installed (required for the webhook component to work)true
cainjector.replicaCountNumber of cert-manager cainjector replicas1
cainjector.podAnnotationsAnnotations to add to the cainjector pods{}
cainjector.podLabelsLabels to add to the cert-manager cainjector pod{}
cainjector.deploymentAnnotationsAnnotations to add to the cainjector deployment{}
cainjector.extraArgsOptional flags for cert-manager cainjector component[]
cainjector.serviceAccount.createIf true, create a new service account for the cainjector componenttrue
cainjector.serviceAccount.nameService account for the cainjector component to be used. If not set and cainjector.serviceAccount.create is true, a name is generated using the fullname template
cainjector.serviceAccount.annotationsAnnotations to add to the service account for the cainjector component
cainjector.resourcesCPU/memory resource requests/limits for the cainjector pods{}
cainjector.nodeSelectorNode labels for cainjector pod assignment{}
cainjector.affinityNode affinity for cainjector pod assignment{}
cainjector.tolerationsNode tolerations for cainjector pod assignment[]
cainjector.image.repositorycainjector image repositoryquay.io/jetstack/cert-manager-cainjector
cainjector.image.tagcainjector image tagv1.2.0
cainjector.image.pullPolicycainjector image pull policyIfNotPresent
cainjector.securityContextSecurity context for cainjector pod assignment{}
cainjector.containerSecurityContextSecurity context to be set on cainjector component container{}

Specify each parameter using the --set key=value[,key=value] argument to helm install.

Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,

$ helm install --name my-release -f values.yaml .

Tip: You can use the default values.yaml

Contributing

This chart is maintained at github.com/jetstack/cert-manager.

Deploy cert-manager with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has cert-manager 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 chartcert-manager is pinned at v1.2.0 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