Install Self-Managed Platform in Amazon Elastic Kubernetes Service (EKS)
This guide provides detailed instructions for deploying the Harness Self-Managed Enterprise Edition on Elastic Kubernetes Service (EKS).
This guide provides step-by-step instructions for deploying the Harness Self-Managed Platform (SMP) on Amazon EKS using Helm charts.
It outlines the necessary prerequisites, configuration steps, and recommended best practices to ensure a secure and efficient deployment on EKS.
Prerequisites
AWS account with necessary IAM permissions to:
Create EKS clusters and node groups.
Create and attach IAM roles and policies.
Provision VPC, subnets, and security groups.
Create and manage IAM OIDC providers and service accounts.
Step 1: Configure Your AWS Account
Open your terminal and run the following command. It will prompt you to enter your AWS credentials:
aws configureProvide your AWS credentials when prompted:
Access Key ID and Secret Access Key: You can access these from the AWS IAM Console.
Default region name: Specify the AWS region where you want to deploy the cluster (e.g., us-east-1).
Default output format: It's recommended to use
json.
Example:
AWS Access Key ID [None]: YOUR_ACCESS_KEY AWS Secret Access Key [None]: YOUR_SECRET_KEY Default region name [None]: YOUR_REGION Default output format [None]: jsonNOTE
Use Step 3 to verify that your AWS account is configured correctly.
If the configuration appears saved but the verification fails, it's possible that the credentials are incorrect, expired, or lack necessary permissions.
Alternatively, you can export the credentials as environment variables, as shown below.
export AWS_ACCESS_KEY_ID=YOUR_ACCESS_KEY export AWS_SECRET_ACCESS_KEY=YOUR_SECRET_KEY export AWS_DEFAULT_REGION=YOUR_REGIONTo verify your configuration, run the following command:
aws sts get-caller-identityIf configured correctly, this command will return your AWS account information as shown below:
{ "UserId": "AROASIYUWQHU2SSQKRFIB:<USER>@email-domain.xyz", "Account": "<ACCOUNT-ID>", "Arn": "arn:aws:sts::156272853481:assumed-role/AWSReservedSSO_AWSPowerUserAccess_687b2d551b4cfd18/<USER>@email-domain.xyz" }For additional help, refer to the official AWS CLI configuration documentation.
Step 2: Provision a Cluster
Create a new YAML file (e.g.,
create-smp-cluster.yaml) using the sample configuration provided below.This configuration will provision an EKS cluster for your SMP environment.
The configuration sets up the following:
A cluster named
<CLUSTER-NAME>in the<YOUR-AWS-REGION>regionManaged node groups
Required IAM policies
Networking settings necessary for running the Harness Self-Managed Platform
The configuration comes with default values suitable for sandbox or testing environments. You can customize the values such as cluster name, region, tags, and CIDR ranges as needed.
Run the following command to create the EKS cluster using the YAML configuration:
Replace
<create-smp-cluster.yaml>with the actual filename if you named it differently.On success, it outputs a final message like:
Step 3: Verify the Cluster Deployment
After provisioning completes, verify the cluster was created successfully using the following commands:
Check the cluster status:
Confirm the nodes are ready:
You should see all worker nodes in a
Readystate, as shown in example below:Confirm the Kubernetes context is set:
This should return the context of your newly created EKS cluster as shown below:
If AWS config is not set, run the following command
If any nodes are in a
NotReadystate or the context is incorrect, ensure yourkubectlis configured correctly and your IAM user has the necessary permissions.
Step 4: Configure the Amazon EBS CSI Driver
To enable dynamic volume provisioning, you need to manually install and configure the EBS CSI driver using the steps below.
Create a namespace for your deployment.
Create an IAM role with a trust policy that allows Amazon EKS to assume the role via IAM Roles for Service Accounts (IRSA).
Begin by creating a
trust-policy.jsonfile with the following content:Once the
trust-policy.jsonfile is created, use the following command to create the IAM role:Attach the
AmazonEBSCSIDriverPolicyto the IAM role:Use the following script to verify that your infrastructure components are functioning correctly and ensure that your Kubernetes cluster is ready to deploy Harness Self-Managed Platform (SMP):
💡 The script checks for Kubernetes connectivity, StorageClass availability, PVC provisioning, pod scheduling, and DNS resolution.
Save the script as
k8s-health-check.sh, make it executable using:Then run it with:
If all checks pass, your cluster is healthy and ready for workloads. ✅
Step 5: Install Self-Managed Platform in Amazon EKS
Download the latest Helm chart from the Harness GitHub Releases page.
In the Assets section, locate and download the
harness-<release-version>.tgz(e.g., harness-0.29.0.tgz) file.Extract the downloaded file and navigate to the extracted directory.
Create a file named
override-new.yamland add the following YAML content to it.Install the Helm chart using the following command.
Verify that all PersistentVolumeClaims (PVCs) have been successfully created and are bound to their respective volumes in your namespace:
Replace
<HARNESS-NAMESPACE>with the namespace where your workloads are deployed.if the PVCs are attached properly, their status will appear as
Bound, as shown below. If the status remainsPending, proceed to step 5 to manually attach the PVCs.Attach the PersistentVolumeClaims (PVCs) by patching each one with the gp2 StorageClass. While you can use other available StorageClasses (such as gp3), this installation uses gp2 by default.
Use the following command to apply the patch in your Harness namespace.
This command will attach the PVCs. Once completed, you can verify the attachment by repeating step 4 above.
Create a Load Balancer by saving the following configuration to a file named
loadbalancer.yaml, and then apply it to your cluster.After saving the file, run the following command to create the Load Balancer in your cluster.
Get the ELB URL by verifying that the LoadBalancer is provisioned and has an external IP using the command below:
Make a note of the
EXTERNAL-IPfor theharness-ingress-controller. It should look like<STRING>.<YOUR-AWS-REGION>.elb.amazonaws.com.Update the
override-new.yamlfile by adding theloadbalancerURLandhostsfields as shown below:Upgrade the Helm deployment, applying your new ELB as the load balancer to your configuration.
Once all components are healthy, you can access SMP by navigating to the sign-up UI at
https://<YOUR_ELB_ADDRESS>/auth/#/signupto create your admin user.Complete to the post-install next steps.
Deploy the Harness modules you want to use. For more information, go to Deploy Harness modules.
Add your Harness license. For more information, go to Add a Harness license.
Configure SMTP to allow for additional user invitations. For more information, go to Add SMTP configuration.
Last updated
Was this helpful?