Skip to content

Latest commit

 

History

History
77 lines (61 loc) · 2.5 KB

File metadata and controls

77 lines (61 loc) · 2.5 KB

Obol Logo

CharonxK8s

This repository contains Kubernetes manifests to deploy a charon cluster.

Please follow the following instructions to deploy a charon cluster to Kubernetes.

Prerequisites

Ensure having docker, a functional Kubernetes cluster and kubectl installed. Install jq package

brew install jq 

Deployment Steps

Cluster Configuration

cp ./envs/.env.sample ./envs/<cluster_name>.env

Edit the required configruation values in the .env file.

Generate Validators Keystores

# Enter required validator addresses
WITHDRAWAL_ADDR=<ENTER YOUR WITHDRAWAL ADDRESS HERE>
FEE_RECIPIENT_ADDR=<ENTER YOUR FEE RECIPIENT ADDRESS HERE>

# Create a distributed validator cluster
docker run --rm -v "$(pwd):/opt/charon" obolnetwork/charon:v1.0.0 create cluster --name="mycluster" --withdrawal-addresses="${WITHDRAWAL_ADDR}" --fee-recipient-addresses="${FEE_RECIPIENT_ADDR}" --nodes 6 --threshold 5

# rename cluster directory to the <cluster_name>
mv .charon/cluster .charon/mycluster

Upload Cluster Config to EKS

aws s3 cp --recursive .charon/<cluster_name>/ s3://charon-clusters-config/<cluster_name>/
aws s3 cp ./envs/<cluster_name>.env s3://charon-clusters-config/<cluster_name>/<cluster_name>.env

OR

Upload Cluster Config to GCP (if setting up canary on GCP)

gcloud storage cp -r .charon/<cluster_name>/ gs://charon-clusters-config/<cluster_name>/
gcloud storage cp .env gs://charon-clusters-config/<cluster_name>/<cluster_name>.env

Generate Lighthouse validators definitions

./scripts/create-lighthouse-validators-definitions.sh <cluster-name>

Generate Lodestar validators definitions

./scripts/create-lodestar-validators-definitions.sh <cluster-name>

Create Kubernetes Secrets for performance cluster (for any cluster which has more than 10 validators)

./scripts/create-cluster-secrets-perf.sh <cluster-name>

Create Kubernetes Secrets

./scripts/create-cluster-secrets.sh <cluster-name>

Deploy Charon Performance Cluster (for any cluster which has more than 10 validators)

./scripts/deploy-cluster-with-charon-tag-perf.sh <cluster-name> <commit-sha>

Deploy Charon Cluster

./scripts/deploy-cluster-with-charon-tag.sh <cluster-name> <commit-sha>