Installation

Requirements#

  • Kubernetes v1.11+ cluster
  • Cert manager v0.15+

Kubernetes cluster#

For development and testing purposes we recommend using kind (Kubernetes in Docker), it's an easy way to create and tear down kubernetes clusters in seconds. For staging and production purposes you can use any public cloud kubernetes as a service like Amazon EKS, Azure AKS or Google GKE.

kind installation guide can be found here.

cert-manager#

cert-manager is a native Kubernetes certificate management controller. It can help with issuing certificates from a variety of sources, such as Let’s Encrypt, HashiCorp Vault, a simple signing key pair, or self-signed. It will ensure certificates are valid and up to date, and attempt to renew certificates at a configured time before expiry.

Kotal webhook component uses cert-manager for issuing certificates to default and validate your networks and nodes.

cert-manager installation guide can be found here.

Install kotal operator#

$ kubectl apply -f https://github.com/kotalco/kotal/releases/download/v0.1-alpha.2/kotal.yaml

Deploy network#

Create rinkeby.yaml manifest that describes a single node with rpc enabled that will join rinkeby test network.

apiVersion: ethereum.kotal.io/v1alpha1
kind: Network
metadata:
name: network-sample
spec:
join: rinkeby
nodes:
- name: node-1
rpc: true

deploy the network using kubectl

$ kubectl apply -f rinkeby.yaml
network.ethereum.kotal.io/network-sample created

within a couple of seconds the network will be up and running. you can get the network using

$ kubectl get networks
NAME JOIN NODES
network-sample rinkeby 1

get the pods by

$ kubectl get pods
NAME READY STATUS RESTARTS AGE
network-sample-node 1/1 Running 0 1m

get logs of rinkeby node-1

$ kubectl logs -f network-sample-node-1

finally delete the network that sync rinkeby by

$ kubectl delete network network-sample
network.ethereum.kotal.io "network-sample" deleted

Congratulations! you have deployed your first network that connects to Rinkeby test network and syncs its blockchain.