ObolNetwork / charon

Charon (pronounced 'kharon') is a Proof of Stake Ethereum Distributed Validator Client
https://docs.obol.tech/
Other
197 stars 88 forks source link

bump old clusters to config v1.7 #2324

Closed xenowits closed 1 year ago

xenowits commented 1 year ago

🎯 Problem to be solved

We recently introduced pregenerated registrations feature which works with cluster configs with version >= v1.7. This feature enables blinded beacon blocks in obol clusters with any validator client.

But the older clusters (config <= v1.6) don't support this feature and as a result can't run blinded blocks with validator clients other than teku.

🛠️ Proposed solution

Design a tool/script, preferably a go program, which bumps old clusters to v1.7 config version.

It should do a charon combine command first followed by a charon create cluster --split-keys.

# Step1: Charon combine
mkdir recombined_keys
charon combine --output-dir=recombined_keys --cluster-dir=.charon/cluster

# Step2: Charon create cluster --split-keys
charon create cluster \
--name="cluster_name" \
--withdrawal-addresses="0x9FD..a410" \
--fee-recipient-addresses="0x9FD..a410" \
--split-existing-keys \
--split-keys-dir=recombined_keys \
--cluster-dir=cluster_dir \
--nodes=4 \
--threshold=3 \
--network=goerli \
--clean

Or an alternative solution would be to reuse code from DKG for this:

🧪 Tests

None.

❌ Out of Scope

None.

boulder225 commented 1 year ago

@OisinKyne TBD

xenowits commented 1 year ago

Closing this since we don't really need a migration tool as of now.

We can always do a manual charon combine and then split-keys:

# Step1: Charon combine
mkdir recombined_keys
charon combine --output-dir=recombined_keys --cluster-dir=.charon/cluster

# Step2: Charon create cluster --split-keys
charon create cluster \
--name="cluster_name" \
--withdrawal-addresses="0x9F..10" \
--fee-recipient-addresses="0x9F..10" \
--split-existing-keys \
--split-keys-dir=recombined_keys \
--cluster-dir=cluster_dir \
--nodes=4 \
--threshold=3 \
--network=goerli \
--clean