insights-agent

by Fairwinds

Helm chartv6.29.2App 9.2.1Verified publisher

A Helm chart to run the Fairwinds Insights agent

About this chart

Fairwinds Insights Agent

The Fairwinds Insights Agent is a collection of reporting tools, which send data back to Fairwinds Insights.

A list of breaking changes for each major version release is available at the bottom of this document.

Changes in 6.0.0

Most plugin image defaults now come from Google Artifact Registry (us-docker.pkg.dev/fairwinds-ops/oss/...) instead of Quay, pinned to immutable semver tags. If you mirror images or allow registries explicitly, update your configuration before upgrading. Still on Quay: insights-right-sizer and vpa-*.

Installation

We recommend installing insights-agent in its own namespace.

helm repo add fairwinds-stable https://charts.fairwinds.com/stable
helm upgrade --install insights-agent fairwinds-stable/insights-agent \
  --namespace insights-agent \
  --set insights.organization=acme-co \
  --set insights.cluster=staging \
  --set insights.base64token="abcde=="

CronJob schedules

Most Insights reports run as CronJobs, typically every hour.

In order to avoid every report consuming resources at once, you can stagger the reports by setting the minute of the cron schedule to a random number. For example, to run at a random minute every hour, your cron expression can be rand * * * *.

Reports

There are several different report types which can be enabled and configured:

  • polaris
  • goldilocks
  • workloads
  • kube-hunter
  • trivy
  • image-trust
  • nova
  • rbac-reporter
  • kube-bench
  • pluto
  • opa
  • prometheus-metrics
  • admission
  • cloudcosts (AWS, GCP, or Azure; optional FOCUS format)
  • network-observability

See below for configuration details.

Fleet Installation

If you're installing the Insights Agent across a large fleet of clusters, it can be tedious to use the UI to create each cluster, then copy out the cluster's access token.

To better serve customers with a large number of clusters, we've created a flow that allows you to easily deploy the Insights Agent across your fleet. Read more here

Configuration

ParameterDescriptionDefault
insights.organizationThe name of the organization to upload data to""
insights.clusterThe name of the cluster the data is coming from""
insights.base64tokenYour cluster's base64-encoded auth token provided by Insights""
insights.tokenSecretNameIf you don't provide a base64token, you can specify the name of a secret to pull the token from""
insights.hostThe location of the Insights serverhttps://insights.fairwinds.com
rbac.disabledDon't use any of the built-in RBACfalse
fleetInstallSee Fleet Installation docsfalse
global.proxy.httpAnnotations used to access the proxy servers(http)""
global.proxy.httpsAnnotations used to access the proxy servers(https)""
global.proxy.ftpAnnotations used to access the proxy servers(ftp)""
global.proxy.no_proxyAnnotations to provides a way to exclude traffic destined to certain hosts from using the proxy""
global.sslCertFileSecretNameThe name of an existing Secret containing an SSL certificate file to be used when communicating with a self-hosted Insights API.""
global.sslCertFileSecretKeyThe key, within global.sslCertFileSecretName, containing an SSL certificate file to be used when communicating with a self-hosted Insights API.""
customWorkloadAnnotationsAdditional annotations to add to each workload. (excluding Falco, uses metadata){}
insights.apiTokenOnly needed if fleetInstall=true""
uploader.image.repositoryThe repository to pull the uploader script fromus-docker.pkg.dev/fairwinds-ops/oss/insights-uploader
uploader.imagePullSecretA pull secret for a private uploader image
uploader.image.tagThe tag to use for the uploader script0.6.12
uploader.resourcesCPU/memory requests and limits for the uploader script
uploader.sendFailuresSend logs of failure to Insights when a job fails.true
uploader.envSet extra environment variables for the uploader script[]
installReporter.ttlSet to -1 to prevent install reporter job from cleaning up after itself300
cronjobs.disableServiceMeshAdds annotations to all CronJobs to not inject Linkerd or Istiotrue
cronjobs.backoffLimitBackoff limit to use for each report CronJob1
cronjobs.imagePullSecretA pull secret for cronjob images
cronjobs.failedJobsHistoryLimitNumber of failed jobs to keep in history for each report1
cronjobs.successfulJobsHistoryLimitNumber of successful jobs to keep in history for each report1
cronjobs.nodeSelectorNode selector to use for cronjobsnull
cronjobs.tolerationsTolerations to use for cronjobsnull
cronjobs.runJobsImmediatelyRun each of the reports immediately upon install of the Insights Agenttrue
cronjobs.suspendSuspend all report CronJobs. Jobs created by runJobsImmediately still run.false
cronjobs.dnsPolicyAdds pod DNS policy
cronjobs.imagePullSecretName of a pull secret to attach to all CronJobs
{report}.enabledEnable the report type
{report}.scheduleCron expression for running the reportrand * * * *
{report}.timeoutMaximum time in seconds to wait for the report
{report}.resourcesCPU/memory requests and limits for the report
{report}.securityContextAdditional securityContext field in the Pod specification(PodSecurityContext) for the report
{report}.image.repositoryRepository to use for the report image
{report}.image.tagImage tag to use for the report
{report}.securityContextPod securityContext for the CronJob{}
{report}.containerSecurityContextContainer securityContext for the CronJob{}
{report}.labelslabels for the CronJob{}
{report}.annotationsannotations for the CronJob{}
{report}.jobLabelslabels for the Jobs created by the CronJob{}
{report}.jobAnnotationsannotations for the Jobs created by the CronJob{}
polaris.configA custom polaris configuration
polaris.extraArgsA string of custom arguments to pass to the polaris CLI, e.g. --disallow-annotation-exemptions=true
kube-hunter.logLevelDEFAULT, INFO, or WARNINGINFO
kube-bench.modeChanges the way this plugin is deployed, either cronjob where it will run a single pod on the schedule that will pull the data necessary from a single node and report that back to Insights. daemonset which deploys a daemonset to the cluster which gathers data then a cronjob will gather data from each of those pods. daemonsetMaster is the same as daemonset except the daemonset can also run on masters.cronjob
kube-bench.hourIntervalIf running in daemonset or daemonsetMaster this configuration changes how often the daemonset pods will rescan the node they are running on2
kube-bench.aggregatorcontains resources and image.repository and image.tag, this controls the pod scheduled via a CronJob that aggregates from the daemonset in daemonset or daemonsetMaster deployment modes.
trivy.ignoreUnfixedAdds --ignore-unfixed trivy flagfalse
trivy.insecureSSLCan be used to allow insecure connections to a container registry when using SSL.false
trivy.privateImages.dockerConfigSecretName of a secret containing a docker config.json""
trivy.maxConcurrentScansMaximum number of scans to run concurrently1
trivy.maxScansPerRunMaximum number of images to scan on a single run20
trivy.namespaceAllowlistSpecifies which namespaces to scan, takes an array of namespaces for example: --set trivy.namespaceAllowlist="{kube-system,default}"[]
trivy.namespaceBlocklistSpecifies which namespaces to not scan, takes an array of namespaces for example: --set trivy.namespaceBlocklist="{kube-system,default}"[]
trivy.serviceAccount.annotationsAnnotations to add to the Trivy service account, e.g. eks.amazonaws.com/role-arn: arn:aws:iam::ACCOUNT_ID:role/IAM_ROLE_NAME for accessing private imagesnil
trivy.envA map of environment variables that will be set for the trivy container.nil
image-trust.enabledEnable Cosign image trust reportingfalse
image-trust.modesModes: cosign-keyless, cosign-key, cosign-attestation-keyless, cosign-attestation-key[cosign-keyless]
image-trust.modePolicyany (first successful mode in list order) or all (every configured mode must verify)any
image-trust.trustedIssuersOIDC issuers for keyless verification[]
image-trust.trustedSubjectsExact certificate identities for keyless verification[]
image-trust.trustedSubjectRegexpsSubject regexes for keyless verification[]
image-trust.attestations.enabledEnable attestation verification; auto-appends cosign-attestation-* modesfalse
image-trust.attestations.typesPredicate types (e.g. slsaprovenance1); setting types alone also enables attestations[]
image-trust.attestationTypesDeprecated; use attestations.types[]
image-trust.imageAllowlistGlob patterns; matching images do not generate findings[]
image-trust.registryAllowlistGlob patterns for registries[]
image-trust.signerAllowlistIssuer, subject, or issuer|subject signer patterns[]
image-trust.publicKeys.secretNameSecret with .pub / PEM files mounted at /etc/image-trust/keys""
image-trust.publicKeys.pathsAbsolute paths to public keys inside the container[]
image-trust.publicKeys.refsRemote/KMS public key URIs[]
image-trust.privateImages.dockerConfigSecretSecret containing config.json for multi-registry auth""
image-trust.privateImages.registryAuthsSecretSecret with JSON array mounted for IMAGE_TRUST_REGISTRY_AUTHS_FILE""
image-trust.privateImages.registryPasswordSecretSecret with registry password for private images""
image-trust.privateImages.registryUserRegistry username when not using docker config""
image-trust.registryMirrorsmirror=upstream pairs for pull-through registries""
image-trust.registryMirrorsFile.secretSecret with mirror pairs (IMAGE_TRUST_REGISTRY_MIRRORS_FILE)""
image-trust.registryCertDirsPer-registry custom CA bundles (host=/path pairs); mount CA directories at those paths (e.g. via image-trust.env)""
image-trust.registryCertDirsFile.secretSecret with cert dir pairs (IMAGE_TRUST_REGISTRY_CERT_DIRS_FILE); mount CA directories at the paths in the file""
image-trust.registryAuthHostDocker config host key for legacy REGISTRY_USER / password""
image-trust.sigstore.envPrivate Sigstore env vars (Fulcio, Rekor URLs){}
image-trust.sigstore.envFileSecretSecret with KEY=VALUE lines for IMAGE_TRUST_SIGSTORE_ENV_FILE""
image-trust.sigstore.trustBundleSecretSecret with Sigstore root bundle (SIGSTORE_ROOT_FILE)""
image-trust.namespaceAllowlistNamespaces to scan[]
image-trust.namespaceBlocklistNamespaces to exclude[]
image-trust.maxConcurrentScansParallel cosign verifications per run5
image-trust.imageVerifyTimeoutSecondsPer-image verify timeout in seconds180
image-trust.verifyRetriesRetries for transient registry/Sigstore errors3
image-trust.verifyRetryBackoffSecondsBase delay between retries2
image-trust.verifyRetryJitterAdd random jitter to retry backofftrue
image-trust.resolveDigestsResolve tag-only images via registry APItrue
image-trust.ignoreTlogSkip Rekor for keyed verificationfalse
image-trust.envExtra environment variables for the image-trust container{}
onDemandJobRunner.image.tagOn-demand job runner image tag; use 0.2.19 or newer for on-demand image-trust jobs0.2.29
opa.roleSpecifies which ClusterRole to grant the OPA agent access toview
opa.additionalAccessSpecifies additional access to grant the OPA agent. This should contain an array of objects with each having an array of apiGroups, an array of resources, and an array of verbs. Just like a RoleBinding.null
insights-agent chart twice you will want to set this flag to false on one of the installs, doesn't matter which.true
opa.targetResourcesA user-specified list of Kubernetes targets to which OPA policies will be applied. Each target requires a list of apiGroups and a list of Resources.{}
opa.targetResourcesAutoRBACAutomatically add RBAC rules allowing get and list operations for APIGroups and Resources supplied via targetResources. This does not impact RBAC rules added for defaultTargetResources.true
opa.admissionRulesAsTargetResourcesIF the admission controller is enabled, the APIGroups and Resources found in insights-admission webhookConfig.rules will be added as OPA Kubernetes target resources, plus supporting RBAC rules are granted to OPA, if the insights-admission webhookConfig.rulesAutoRBAC value is also set.true
goldilocks.controller.flags.exclude-namespacesNamespaces to exclude from the goldilocks reportkube-system
goldilocks.vpa.enabledInstall the Vertical Pod Autoscaler as part of the Goldilocks installationtrue
goldilocks.controller.flags.on-by-defaultGoldilocks will by default monitor all namespaces that aren't excludedtrue
goldilocks.controller.resourcesCPU/memory requests and limits for the Goldilocks controller
goldilocks.dashboard.enabledInstalls the Goldilocks Dashboardfalse
prometheus-metrics.installPrometheusServerInstall a new Prometheus server instance for the prometheus reportfalse
prometheus-metrics.addressThe address of an existing Prom

Deploy insights-agent with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has insights-agent 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 chartinsights-agent is pinned at v6.29.2 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