Deploy Beacon Node
The Beacon Chain is the coordination mechanism of the new network, responsible for creating new blocks, making sure those new blocks are valid, and rewarding validators with ETH for keeping the network secure. Source
Deploy Beacon Node
apiVersion: ethereum2.kotal.io/v1alpha1
kind: BeaconNode
metadata:
name: teku-beacon-node
spec:
network: pyrmont
client: teku
rest: true
restPort: 8888
eth1Endpoints:
- http://goerli-besu-node:8545In this beacon node, we're using ConsenSys Teku Ethereum 2.0 client client: teku, and syncing the pyrmont network beacon chain network: pyrmont. We also enable REST API server rest: true at port 8888 restPort: 8888. We're connecting to Ethereum 1 endpoint eth1Endpoints: .... Check Ethereum tutorial on how to deploy an Ethereum node.
Let's deploy the beacon node:
kubectl apply -f beacon.yamlKotal operator will notice your teku-beacon-node and will create all the necessary pods, persistent volumes, services, configmaps, and secrets.
You can fetch the deployed Ethereum 2.0 BeaconNode using:
kubectl get beaconnodesIt will return an output similar to the following:
Fetch Beacon Node Logs
Get the pods created for the beacon node:
It will return an output similar to the following:
Get the logs of the running beacon node:
Call /eth/v1/beacon/genesis REST API
/eth/v1/beacon/genesis REST APIGet the service created for the beacon node:
It will return an output similar to the following:
Forward the localhost:8888 calls to the beacon node
In another terminal window, send REST API call to get chain genesis details:
You'll get a result similar to the following:
Finally delete the beacon node:
Kubernetes garbage collector will delete all the resources that has been created by Kotal Ethereum 2.0 BeaconNode controller.
Last updated
Was this helpful?