rhacs-setup

by tjungbauer

Helm chartv1.0.52Apache-2.0Verified publisher

Master chart to deploy RHACS operator, initialize it and do some configuration using API Calls

About this chart

rhacs-setup

Description

Master chart to deploy RHACS operator, initialize it and do some configuration using API Calls

This Helm Chart is installing and configuring Advanced Cluster Security, using the following workflow:

  1. Create required Namespace for the operator.
  2. Installing the ACS operator by applying the Subscription and OperatorGroup object. (In addition, the InstallPlan can be approved if required)
  3. Verifying if the operator is ready to use Install and configure the compliance operator.
  4. Create the Namespace for Stackrox instance.
  5. Deploy the Central
  6. Create an init-Bundle for the Secured Cluster
  7. Deploy the Secured Cluster instance on the Central cluster.
  8. Job: Create a ConsoleLink for eady access of ACS.
  9. Job: Configure ACS with OpenShift Authentication for the user kubeadmin

The whole process has multiple hooks and waves, which are illustrated in the image:

Dependencies

This chart has the following dependencies:

RepositoryNameVersion
https://charts.stderr.at/tpl~1.0.31

It is best used with a full GitOps approach such as Argo CD does. For example, https://github.com/tjungbauer/openshift-clusterconfig-gitops (folder: clusters/management-cluster/setup-acs)

Maintainers

NameEmailUrl
tjungbauer[email protected]https://blog.stderr.at/

Sources

Source:

Source code: https://github.com/tjungbauer/helm-charts/tree/main/charts/rhacs-setup

Parameters

Verify the subcharts for additional settings:

Values

KeyTypeDefaultDescription
clusternamestring"local-cluster"
helper-operator.operators.rhacs-operator.enabledboolfalse
helper-operator.operators.rhacs-operator.namespace.createboolfalse
helper-operator.operators.rhacs-operator.namespace.namestring"rhacs-operator"
helper-operator.operators.rhacs-operator.operatorgroup.createbooltrue
helper-operator.operators.rhacs-operator.operatorgroup.notownnamespacebooltrue
helper-operator.operators.rhacs-operator.subscription.approvalstring"Automatic"
helper-operator.operators.rhacs-operator.subscription.channelstring"stable"
helper-operator.operators.rhacs-operator.subscription.operatorNamestring"rhacs-operator"
helper-operator.operators.rhacs-operator.subscription.sourcestring"redhat-operators"
helper-operator.operators.rhacs-operator.subscription.sourceNamespacestring"openshift-marketplace"
helper-operator.operators.rhacs-operator.syncwavestring"0"
helper-status-checker.checks[0].namespace.namestring"rhacs-operator"
helper-status-checker.checks[0].operatorNamestring"rhacs-operator"
helper-status-checker.checks[0].serviceAccount.namestring"status-checker-acs"
helper-status-checker.checks[0].syncwaveint3
helper-status-checker.enabledboolfalse
operatornamespacestring"rhacs-operator"
override-rhacs-operator-versionstring"stable"
rhacs.basic_acs_settingsobject{"additionalAnnotations":{},"additionalLabels":{},"auth_provider":"OpenShift","auth_provider_type":"openshift","min_access_role":"None","syncwave":5}Basic settings for ACS authentication This configuration is done by a Job, that will configure the OpenShift oauth for ACS.
rhacs.central.additionalAnnotationsobject{}
rhacs.central.additionalLabelsobject{}
rhacs.central.adminPasswordSecretstringomittedSpecify a secret that contains the administrator password in the "password" data item. If omitted, the operator will auto-generate a password and store it in the "password" item in the "central-htpasswd" secret. The Secret must exist.
rhacs.central.dbobject{"nodeSelector":{"key":"node-role.kubernetes.io/infra","value":""},"passwordSecret":"secretname","pvc":"central-db","pvc_size":"100Gi","pvc_storageclass":"storageclass","resources":{"limits":{"cpu":8,"ephemeral-storage":"500Mi","memory":"16Gi"},"requests":{"cpu":4,"ephemeral-storage":"50Mi","memory":"8Gi"}},"tolerations":[{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"},{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"}]}Settings for Central DB, which is responsible for data persistence.
rhacs.central.db.nodeSelectorobjectemptyDefine nodeSelector for Sensor.
rhacs.central.db.passwordSecretstringomittedSpecify a secret that contains the password in the "password" data item. This can only be used when specifying a connection string manually. When omitted, the operator will auto-generate a DB password and store it in the "password" item in the "central-db-password" secret.
rhacs.central.db.pvcstringcentral-dbConfigures how Central DB should store its persistent data. The name of the PVC to manage persistent data. If no PVC with the given name exists, it will be created. Defaults to "central-db" if not set.
rhacs.central.db.pvc_sizestringemptyThe size of the persistent volume when created through the claim. If a claim was automatically created, this can be used after the initial deployment to resize (grow) the volume (only supported by some storage class controllers).
rhacs.central.db.pvc_storageclassstringemptyThe name of the storage class to use for the PVC. If your cluster is not configured with a default storage class, you must select a value here.
rhacs.central.db.resourcesobject{"limits":{"cpu":8,"ephemeral-storage":"500Mi","memory":"16Gi"},"requests":{"cpu":4,"ephemeral-storage":"50Mi","memory":"8Gi"}}Set Central DB resources.requests and resources.limits. Per default this block can be omitted.
rhacs.central.db.resources.limits.cpuint4CPU limits.
rhacs.central.db.resources.limits.ephemeral-storagestringemptyStorage limits
rhacs.central.db.resources.limits.memorystring8GiMemory limits.
rhacs.central.db.resources.requests.cpuint4CPU requests.
rhacs.central.db.resources.requests.ephemeral-storagestringemptyStorage requests
rhacs.central.db.resources.requests.memorystring8GiMemory requests.
rhacs.central.db.tolerationslist[{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"},{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"}]If you want this component to only run on specific nodes, you can configure tolerations of tainted nodes.
rhacs.central.declarativeConfigurationobjectemtpyDefine ConfigMaps with DeclerativeConfiguration
rhacs.central.defaultsslsecretstring"secretname"By default, Central will only serve an internal TLS certificate, which means that you will need to handle TLS termination at the ingress or load balancer level. If you want to terminate TLS in Central and serve a custom server certificate, you can specify a secret containing the certificate and private key here. Define here the name of the secret If you would like to set it. The secret must exist.
rhacs.central.egressobject{"connectivityPolicy":"Online"}Configures whether Red Hat Advanced Cluster Security should run in online or offline (disconnected) mode. In offline mode, automatic updates of vulnerability definitions and kernel modules are disabled. This parameter is MANDATORY default -- Online
rhacs.central.enabledboolfalseEnabled yes or not. Typically, a Central is installed only once (maybe on the management cluster) and will manage different external clusters.
rhacs.central.loadBalancerobject{"enabled":false,"ip":"127.0.0.1","port":443}Expose Central through a load balancer service.
rhacs.central.loadBalancer.enabledboolfalseEnable load balancer services.
rhacs.central.loadBalancer.ipstring"127.0.0.1"IP Address of the loadbalancer services.
rhacs.central.loadBalancer.portint443Port of the load balancer service
rhacs.central.monitoringstringDisabledEnables monitoring endpoint for Central to allow other services to collect metrics from the Central. Can be either Enabled of Disabled.
rhacs.central.nodePortobject{"enabled":false}Expose Central through a node port.
rhacs.central.nodeSelectorobjectemptyDefine nodeSelector for Sensor.
rhacs.central.pvcstringstackrox-dbThe name of the PVC to manage persistent data. If no PVC with the given name exists, it will be created. Defaults to "stackrox-db" if not set.
rhacs.central.pvc_sizestringemptyThe size of the persistent volume when created through the claim. If a claim was automatically created, this can be used after the initial deployment to resize (grow) the volume (only supported by some storage class controllers).
rhacs.central.pvc_storageclassstringdefault storage class will be usedThe name of the storage class to use for the PVC. If your cluster is not configured with a default storage class, you must select a value here.
rhacs.central.resourcesobject{"limits":{"cpu":4,"ephemeral-storage":"500Mi","memory":"8Gi"},"requests":{"cpu":"500m","ephemeral-storage":"50Mi","memory":"1Gi"}}Set resources.requests and resources.limits. Per default this block can be omitted.
rhacs.central.resources.limits.cpuint4CPU limits.
rhacs.central.resources.limits.ephemeral-storagestringemptyStorage limits
rhacs.central.resources.limits.memorystring8GiMemory limits.
rhacs.central.resources.requests.cpustring1500mCPU requests.
rhacs.central.resources.requests.ephemeral-storagestringemptyStorage requests
rhacs.central.resources.requests.memorystring4GiMemory requests.
rhacs.central.routeobject{"enabled":true}Expose Central through an OpenShift route. This is the default setting
rhacs.central.syncwavestring3Syncwave for Argo CD to create the Central
rhacs.central.tolerationslist[{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"},{"effect":"NoSchedule","key":"infra","operator":"Equal","value":"reserved"}]If you want this component to only run on specific nodes, you can configure tolerations of tainted nodes.
rhacs.consolelinkobject{"additionalAnnotations":{},"additionalLabels":{},"enabled":true,"location":"ApplicationMenu","section":"Observability","syncwave":"3","text":"Advanced Cluster Security"}Job that creates a console link in OpenShift
rhacs.consolelink.enabledboolfalseEnable this Job
rhacs.consolelink.locationstring"ApplicationMenu"Location of the ConsoleLink
rhacs.consolelink.sectionstring"Observability"Section of the ConsoleLink
rhacs.consolelink.syncwavestring3Syncwave for Argo CD to create this Job.
rhacs.consolelink.textstring"Advanced Cluster Security"Text of the ConsoleLink
rhacs.job_init_bundleobject{"additionalAnnotations":{},"additionalLabels":{},"enabled":true,"syncwave":"3"}Run the Job to initialze an ACS secrued cluster and creates a init bundle.
rhacs.job_init_bundle.enabledboolfalseEnable this Job
rhacs.job_init_bundle.syncwavestring3Syncwave for Argo CD to create this Job.
rhacs.job_varsobject{"max_attempts":20}Variables for Jobs
rhacs.job_vars.max_attemptsint20Maximum retries for Jobs that need to check a certain state.
rhacs.namespace.additionalAnnotationsobject{}
rhacs.namespace.additionalLabelsobject{}
rhacs.namespace.descrstring"Red Hat Advanced Cluster Security"Description of the Namespace.
rhacs.namespace.namestring"stackrox"Namespace where ACS shall be deployed. Typicall, this is stackrox. This is not the Operator itself, that is usually deployed in "rhacs-operator".
rhacs.namespace.syncwavestring0Syncwave to deploy the ACS namespace.
rhacs.scanner.analyzer.autoscalingobject{"max":3,"min":2,"replicas":3,"status":"Enabled"}Automatically scale the Scanner
rhacs.scanner.analyzer.autoscaling.maxint3Max number of Pods
rhacs.scanner.analyzer.autoscaling.minint2Minimum number of Pods
rhacs.scanner.analyzer.autoscaling.replicasint3When autoscaling is disabled, the number of replicas will always be configured to match this value.
rhacs.scanner.analyzer.autoscaling.statusstringEnabledIs austoscaling enabled?
rhacs.scanner.analyzer.nodeSelectorobjectemptyDe

Deploy rhacs-setup with OpenTenant

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