bitnamicharts/contour
Bitnami Helm chart for Contour
5M+
Contour is an open source Kubernetes ingress controller that works by deploying the Envoy proxy as a reverse proxy and load balancer.
Trademarks: This software listing is packaged by Bitnami. The respective trademarks mentioned in the offering are owned by the respective companies, and use of them does not imply any affiliation or endorsement.
helm install my-release oci://registry-1.docker.io/bitnamicharts/contour
Looking to use Contour in production? Try VMware Tanzu Application Catalog, the commercial edition of the Bitnami catalog.
Bitnami charts for Helm are carefully engineered, actively maintained and are the quickest and easiest way to deploy containers on a Kubernetes cluster that are ready to handle production workloads.
This chart bootstraps a Contour Ingress Controller Deployment and a Envoy Proxy Daemonset on a Kubernetes cluster using the Helm package manager.
Bitnami charts can be used with Kubeapps for deployment and management of Helm Charts in clusters.
ServiceType: LoadBalancer
like MetalLBTo install the chart with the release name my-release
:
helm install my-release oci://REGISTRY_NAME/REPOSITORY_NAME/contour
Note: You need to substitute the placeholders
REGISTRY_NAME
andREPOSITORY_NAME
with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to useREGISTRY_NAME=registry-1.docker.io
andREPOSITORY_NAME=bitnamicharts
.
These commands deploy contour on the Kubernetes cluster in the default configuration. The Parameters section lists the parameters that can be configured during installation.
Tip: List all releases using
helm list
orhelm ls --all-namespaces
Bitnami charts allow setting resource requests and limits for all containers inside the chart deployment. These are inside the resources
value (check parameter table). Setting requests is essential for production workloads and these should be adapted to your specific use case.
To make this process easier, the chart contains the resourcesPreset
values, which automatically sets the resources
section according to different presets. Check these presets in the bitnami/common chart. However, in production workloads using resourcesPreset
is discouraged as it may not fully adapt to your specific needs. Find more information on container resource management in the official Kubernetes documentation.
This chart can be integrated with Prometheus by setting metrics.enabled
to true. This will expose the Contour and Envoy (if envoy.service.exposeMetrics=true
) native Prometheus ports in the containers. Additionally, it will deploy several metrics
services. These metrics
services will have the necessary annotations to be automatically scraped by Prometheus.
Prometheus requirements
It is necessary to have a working installation of Prometheus or Prometheus Operator for the integration to work. Install the Bitnami Prometheus helm chart or the Bitnami Kube Prometheus helm chart to easily have a working Prometheus in your cluster.
Integration with Prometheus Operator
The chart can deploy ServiceMonitor
objects for integration with Prometheus Operator installations. To do so, set the value metrics.serviceMonitor.enabled=true
. Ensure that the Prometheus Operator CustomResourceDefinitions
are installed in the cluster or it will fail with the following error:
no matches for kind "ServiceMonitor" in version "monitoring.coreos.com/v1"
Install the Bitnami Kube Prometheus helm chart for having the necessary CRDs and the Prometheus Operator.
It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image.
Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist.
To configure Contour please look into the configuration section Contour Configuration.
To back up and restore Helm chart deployments on Kubernetes, you need to back up the persistent volumes from the source deployment and attach them to a new deployment using Velero, a Kubernetes backup/restore tool. Find the instructions for using Velero in this guide.
configInline:
# should contour expect to be running inside a k8s cluster
# incluster: true
#
# path to kubeconfig (if not running inside a k8s cluster)
# kubeconfig: /path/to/.kube/config
#
# Client request timeout to be passed to Envoy
# as the connection manager request_timeout.
# Defaults to 0, which Envoy interprets as disabled.
# Note that this is the timeout for the whole request,
# not an idle timeout.
# request-timeout: 0s
# disable ingressroute permitInsecure field
disablePermitInsecure: false
tls:
# minimum TLS version that Contour will negotiate
# minimum-protocol-version: "1.1"
# Defines the Kubernetes name/namespace matching a secret to use
# as the fallback certificate when requests which don't match the
# SNI defined for a vhost.
fallback-certificate:
# name: fallback-secret-name
# namespace: projectcontour
# The following config shows the defaults for the leader election.
# leaderelection:
# configmap-name: leader-elect
# configmap-namespace: projectcontour
### Logging options
# Default setting
accesslog-format: envoy
# To enable JSON logging in Envoy
# accesslog-format: json
# The default fields that will be logged are specified below.
# To customise this list, just add or remove entries.
# The canonical list is available at
# https://godoc.org/github.com/projectcontour/contour/internal/envoy#JSONFields
# json-fields:
# - "@timestamp"
# - "authority"
# - "bytes_received"
# - "bytes_sent"
# - "downstream_local_address"
# - "downstream_remote_address"
# - "duration"
# - "method"
# - "path"
# - "protocol"
# - "request_id"
# - "requested_server_name"
# - "response_code"
# - "response_flags"
# - "uber_trace_id"
# - "upstream_cluster"
# - "upstream_host"
# - "upstream_local_address"
# - "upstream_service_time"
# - "user_agent"
# - "x_forwarded_for"
#
# default-http-versions:
# - "HTTP/2"
# - "HTTP/1.1"
#
# The following shows the default proxy timeout settings.
# timeouts:
# request-timeout: infinity
# connection-idle-timeout: 60s
# stream-idle-timeout: 5m
# max-connection-duration: infinity
# connection-shutdown-grace-period: 5s
By default, Contour is launched with an AWS Classic ELB. To launch contour backed by a NLB, please set these settings:
envoy:
service:
annotations:
service.beta.kubernetes.io/aws-load-balancer-type: nlb
service.beta.kubernetes.io/aws-load-balancer-ssl-ports: "https"
service.beta.kubernetes.io/aws-load-balancer-connection-idle-timeout: "3600"
service.beta.kubernetes.io/aws-load-balancer-ssl-cert: arn:aws:acm: arn:aws:acm:XX-XXXX-X:XXXXXXXXX:certificate/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX
containerPorts:
http: 80
https: 80
This chart allows you to set your custom affinity using the XXX.affinity
parameter(s). Find more information about Pod's affinity in the kubernetes documentation.
As an alternative, you can use of the preset configurations for pod affinity, pod anti-affinity, and node affinity available at the bitnami/common chart. To do so, set the XXX.podAffinityPreset
, XXX.podAntiAffinityPreset
, or XXX.nodeAffinityPreset
parameters.
Name | Description | Value |
---|---|---|
global.imageRegistry | Global Docker image registry | "" |
global.imagePullSecrets | Global Docker registry secret names as an array | [] |
global.defaultStorageClass | Global default StorageClass for Persistent Volume(s) | "" |
global.storageClass | DEPRECATED: use global.defaultStorageClass instead | "" |
global.security.allowInsecureImages | Allows skipping image verification | false |
global.compatibility.openshift.adaptSecurityContext | Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) | auto |
Name | Description | Value |
---|---|---|
nameOverride | String to partially override contour.fullname include (will maintain the release name) | "" |
fullnameOverride | String to fully override contour.fullname template | "" |
namespaceOverride | String to fully override common.names.namespace | "" |
kubeVersion | Force target Kubernetes version (using Helm capabilities if not set) | "" |
extraDeploy | Array of extra objects to deploy with the release | [] |
commonLabels | Labels to add to all deployed objects | {} |
commonAnnotations | Annotations to add to all deployed objects | {} |
diagnosticMode.enabled | Enable diagnostic mode (all probes will be disabled and the command will be overridden) | false |
diagnosticMode.command | Command to override all containers in the deployment | [] |
diagnosticMode.args | Args to override all containers in the deployment | [] |
Name | Description | Value |
---|---|---|
existingConfigMap | Specifies the name of an externally-defined ConfigMap to use as the configuration (this is mutually exclusive with configInline ) | "" |
configInline | Specifies Contour's configuration directly in YAML format | {} |
contour.enabled | Contour Deployment creation. | true |
contour.image.registry | Contour image registry | REGISTRY_NAME |
contour.image.repository | Contour image name | REPOSITORY_NAME/contour |
contour.image.digest | Contour image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | "" |
contour.image.pullPolicy | Contour Image pull policy | IfNotPresent |
contour.image.pullSecrets | Contour Image pull secrets | [] |
contour.image.debug | Enable image debug mode | false |
contour.contourConfigName | Contour Deployment with ContourConfiguration CRD. | contour |
contour.configPath | Contour Deployment with configmap. | true |
contour.replicaCount | Number of Contour Pod replicas | 1 |
contour.priorityClassName | Priority class assigned to the pods | "" |
contour.schedulerName | Name of the k8s scheduler (other than default) | "" |
contour.terminationGracePeriodSeconds | In seconds, time the given to the Contour pod needs to terminate gracefully | "" |
contour.topologySpreadConstraints | Topology Spread Constraints for pod assignment | [] |
contour.containerPorts.xds | Set xds port inside Contour pod | 8001 |
contour.containerPorts.metrics | Set metrics port inside Contour pod | 8000 |
contour.automountServiceAccountToken | Mount Service Account token in pod | true |
contour.hostAliases | Add deployment host aliases | [] |
contour.updateStrategy | Strategy to use to update Pods | {} |
contour.extraArgs | Extra arguments passed to Contour container | [] |
contour.resourcesPreset | Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if contour.resources is set (contour.resources is recommended for production). | nano |
contour.resources | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | {} |
contour.manageCRDs | Manage the creation, upgrade and deletion of Contour CRDs. | true |
contour.envoyServiceNamespace | Namespace of the envoy service to inspect for Ingress status details. | "" |
contour.envoyServiceName | DEPRECATED: use envoy.service.name | "" |
contour.leaderElectionResourceName | Name of the contour (Lease) leader election will lease. | "" |
contour.ingressStatusAddress | Address to set in Ingress object status. It is exclusive with envoyServiceName and envoyServiceNamespace . | "" |
contour.podAffinityPreset | Contour Pod affinity preset. Ignored if affinity is set. Allowed values: soft or hard |
Note: the README for this chart is longer than the DockerHub length limit of 25000, so it has been trimmed. The full README can be found at https://github.com/bitnami/charts/blob/main/bitnami/contour/README.md