HCE Onboard CLI
This section describes the Harness Chaos Engineering (HCE) onboard CLI and its usage.
What is the HCE onboard CLI?
The onboard_hce_aws
CLI streamlines and simplifies the HCE onboarding process. This tool also seamlessly integrates with your AWS account and executes HCE experiments. This CLI performs other tasks that streamline the onboarding process, such as:
-
ChaosInfra Setup: The CLI installs the chaos infrastructure in the given namespace of your cluster using Harness APIs and Kubernetes permissions. After installation, it tests the activation of the infrastructure for a given timeout (default is 180 s).
-
Add OIDC Provider: The CLI can be used to add the OIDC provider in the target account using the AWS credentials. If the given provider already exists, the CLI issues a warning and skips this step.
-
AWS Roles: Simplifies configuring HCE with AWS. If you wish to create a dedicated role for HCE, the CLI defines the required policies and permissions directly as CLI flags. Alternatively, if you already have a role, you can provide it as an input, and that role gets attached to the provider that you added previously. In addition, this CLI doesn't depend on other CLIs such as
aws
orkubectl
. -
Annotate Service Account: The CLI will annotate the experiment service account on the cluster with AWS roleARN after all the configuration is done.
-
Compatibility: It provides compatibility across various Windows and Linux versions.
-
Flag support: It supports a variety of flags thereby facilitating customization options for every step.
Install the onboard HCE AWS
Onboard HCE AWS offers pre-compiled binaries that are available for download on our releases page.
To install, follow these steps.
- Download the appropriate binary for your platform from the Assets section.
- Rename the downloaded file to
onboard_hce_aws
(oronboard_hce_aws.exe
for Windows). - Move this file to your
$PATH
at your preferred binary installation directory.
- Linux
- MacOS
You can download for AMD64
(or x86_64) and Arm64
variants in Linux OS.
- AMD64 / x86_64
- Arm64
[ $(uname -m) = x86_64 ] && curl -Lo ./onboard_hce_aws https://github.com/harness/onboard_hce_aws/releases/download/0.0.3/cli-linux-amd64
[ $(uname -m) = aarch64 ] && curl -Lo ./onboard_hce_aws https://github.com/harness/onboard_hce_aws/releases/download/0.0.3/cli-linux-arm64
- After downloading, add the execution permissions and move it to your binary installation directory using the following commands:
chmod +x ./onboard_hce_aws
sudo mv ./onboard_hce_aws /usr/local/bin/onboard_hce_aws
You can download for M1/ARM Macs
and Intel Macs
variants in MacOS.
- Intel Macs
- M1 / ARM Macs
[ $(uname -m) = x86_64 ] && curl -Lo ./onboard_hce_aws https://github.com/harness/onboard_hce_aws/releases/download/0.1.0/cli-darwin-amd64
[ $(uname -m) = arm64 ] && curl -Lo ./onboard_hce_aws https://github.com/harness/onboard_hce_aws/releases/download/0.2.0/cli-darwin-arm64
- After downloading, add the execution permissions and move it to your binary installation directory using the following commands:
chmod +x ./onboard_hce_aws
mv ./onboard_hce_aws /some-dir-in-your-PATH/onboard_hce_aws