DevZero Logo
DevZero

Control Plane

Self-hosting a DevZero Control Plane on AWS EKS.

Hosting the DevZero Control Plane on AWS EKS

Control Plane Architecture (AWS EKS)

Prerequisites

Prerequisites and requirements for this doc are the same as AWS Setup.

Deploying the control plane

Clone devzero-inc/self-hosted

git clone https://github.com/devzero-inc/self-hosted.git
cd self-hosted

Contact DevZero Support if you don't have access to the repository.

Set up kubeconfig

Set up your local kubeconfig to connect to the EKS cluster using the region and cluster name from the terraform output:

aws eks update-kubeconfig --region <region> --name <cluster-name>

Set up control plane dependencies

Go to the charts/dz-control-plane-deps directory to modify configurations before running any installation steps.

cd charts/dz-control-plane-deps

If you are using private subnets and traffic is routed through a VPN, add this and replace <private_subnet_1>, <private_subnet_2> and <acm_cert_arn>:

Change control-plane-deps domains from example.com to where DevZero will be hosted (e.g.: devzero.companyx.com)

The DevZero deployment will be available at devzero.companyx.com, Grafana at grafana.devzero.companyx.com, Docker registry at docker-registry.devzero.companyx.com, ...

# in: charts/dz-control-plane-deps
 
# change example.com to devzero.companyx.com in all files in the values/ directory
find values -type f -exec sed -i'.bak' 's/example\.com/devzero\.companyx\.com/g' {} \; && find values -name "*.bak" -delete

Install control plane dependencies

# in: charts/dz-control-plane-deps
make install

Authenticate to Docker Hub

Contact the DevZero team at support@devzero.io to get the Docker Hub credentials to install and set up the DevZero control plane.

# in: charts/dz-control-plane-deps
cd ../dz-control-plane
# in: charts/dz-control-plane

Update the credentials section in charts/dz-control-plane/values.yaml:

  ## @section Credentials Configuration
    credentials:
      ## @param credentials.enable Enable docker hub credentials
      # Comment out image.pullSecrets if you disable this
      enable: true
      ## @param credentials.registry Container registry URL
      registry: "docker.io"
      ## @param credentials.username Registry username
  -   username: ""
  +   username: "engineer"
      ## @param credentials.password Registry password
  -   password: ""
  +   password: "engineer-companyx-password"
      ## @param credentials.email Registry email address
  -   email: ""
  +   email: "engineer@companyx.com"

Change control-plane domains from example.com to where DevZero will be hosted (e.g.: devzero.companyx.com)

The DevZero deployment will be available at devzero.companyx.com, Grafana at grafana.devzero.companyx.com, Docker registry at docker-registry.devzero.companyx.com, ...

# in: charts/dz-control-plane
 
# change example.com to devzero.companyx.com in all files in the values/ directory
find . -name "values.yaml" -exec sed -i'.bak' 's/example\.com/devzero\.companyx\.com/g' {} \; && find . -name "values.yaml.bak" -delete

Contact the DevZero team at support@devzero.io to get a license key to activate the DevZero control plane.

Put the license key into the licenseKey field under the backend block in values.yaml.

## @param backend.licenseKey License key
- licenseKey: ""
+ licenseKey: "companyX:4893935658:hEET8Env/7uDmGcctO/Y3s5tQ ... gwLbaEoy3wYd9gPhgU6I="

Set up control plane

# in: charts/dz-control-plane
make install

DZ Control Plane output

Setup ingress and connect to AWS Route 53

Get the ingress service in the cluster

kubectl get service -n ingress-nginx

Running ingress

Alternatively, run:

kubectl get svc -n ingress-nginx -o jsonpath='{.items[?(@.spec.type=="LoadBalancer")].status.loadBalancer.ingress[*].hostname}'

Copy the address of your ingress services.

Create a CNAME record. Set the name to *. Set the value to the address of the ingress service (copied from previous step).

CNAME Record

Create an A record with an alias, pointing to the load-balancer that was created in AWS.

DevZero dashboard

Go to devzero.companyx.com/dashboard (replace with your actual domain).

DevZero dashboard

Setting up Data Plane on a self-hosted EKS cluster

To set up the data plane in the same cluster, visit DevZero Data Plane on AWS EKS.