Comment on page
Deploying a MAYANode and its associated services.
Now you have a Kubernetes cluster ready to use, you can install the MAYANode services.
Helm charts are the defacto and currently easiest and simple way to package and deploy Kubernetes application. The team created different Helm charts to help to deploy all the necessary services. Please retrieve the source files from the Git repository here to follow the instructions below:
- Running Kubernetes cluster
- Kubectl configured, ready and connected to running cluster
If you came here from the Setup page, you are already good to go.
node-launcherrepo. All commands in this section are to be run inside of this repo.
git clone https://gitlab.com/mayachain/devops/node-launcher
git checkout master
Install Helm 3 if not already available on your current machine:
To deploy all tools, metrics, logs management, Kubernetes Dashboard, run the command below.
To destroy all those resources run the command below.
If you are successful, you will see the following message:
If there are any errors, they are typically fixed by running the command again.
It is important to deploy the tools first before deploying the MAYANode services as some services will have metrics configuration that would fail and stop the MAYANode deployment.
Currently MAYAChain supports BTC, DASH, ETH and THOR. For all of the chains that we support a fullnode is used in order to read transactions from them. Sync time varies from chain to chain, but there's a couple of things you can do to speed up some of them:
By default the fullnode of ETH will connect checkpoint node provided by Maya Protocol. If you want to customize the checkpoint node to use you can edit the
In order to sync THOR from a ninerealms snapshot you need to explicitly enable it by setting
You have multiple commands available to deploy different configurations of MAYANode. You can deploy mainnet or stagenet (currently not churning in third-party nodes). The commands deploy the umbrella chart
mayanode-stackin the background in the Kubernetes namespace
mayanode-stagenetfor stagenet) by default.
If you are intending to run all chain clients, bond in & earn rewards, you want to choose "validator".
Once it's all deployed you'll need to sync from a snapshot.
$ make recover-maya
Maya only provides mainnet snapshots. Continue?
:: Are you sure? Confirm [y/n]: y
=> Select snapshot type
=> Select snapshot height
We recommend choosing the defaults, but in case you have a specific need you can choose otherwise.
You are now ready to join the network:
mayanodeto be your default namespace so you don't need to type
-n mayanodeeach time:
kubectl config set-context --current --namespace=mayanode
Use the following useful commands to view and debug accordingly. You should see everything running and active. Logs can be retrieved to find errors:
kubectl get pods -n mayanode
kubectl get pods --all-namespaces
kubectl logs -f <pod> -n mayanode
Kubernetes should automatically restart any service, but you can force a restart by running:
kubectl delete pod <pod> -n mayanode
Note, to expedite syncing external chains, it is feasible to continually delete the pod that has the slow-syncing chain daemon (eg, binance-daemon-xxx).
Killing it will automatically restart it with free resources and syncing is notably faster. You can check sync status by viewing logs for the client to find the synced chain tip and comparing it with the real-world blockheight, ("xxx" is your unique ID):
kubectl logs -f binance-daemon-xxx -n mayanode
- mayanode: Umbrella chart packaging all services needed to run a fullnode or validator MAYANode.
This should be the only chart used to run MAYANode stack unless you know what you are doing and want to run each chart separately (not recommended).
- mayanode: MAYANode daemon
- gateway: MAYANode gateway proxy to get a single IP address for multiple deployments
- bifrost: Bifrost service
- midgard: Midgard API service
- mayachain-daemon: Mayachain fullnode daemon
- bitcoin-daemon: Bitcoin fullnode daemon
- dash-daemon: Dash fullnode daemon
- ethereum-daemon: Ethereum fullnode daemon
- thornode-daemon: Thorchain fullnode daemon
- chain-daemon: as required for supported chains
- prometheus: Prometheus stack for metrics
- loki: Loki stack for logs
- kubernetes-dashboard: Kubernetes dashboard