Nomos commit: 858ef2c2d76d4aa6df7767a1c01f6d120218e79b
Deployment files location:
https://github.com/vacp2p/10ksim/tree/master/deployment-utilities/kubernetes-utilities
Current Nomos testnet uses compose.static.yml that spawns docker containers locally in the same machine. The docker image has every needed functionality in the same image:
In order to avoid creating local volumes from the compose, we recompiled the Docker image adding the necessary files.
Then, we created 2 StatefulSets, one for nomos-executor and another one for nomos-node.
At the begining we discovered a small issue in the cfgsync.yaml:
root@b7f2d7221d6d:/# ./etc/nomos/scripts/run_cfgsync.sh
Failed to parse config file: tracing_settings: missing field console at line 35 column 3
Quickly resolved by the Nomos team with the following PR:
https://github.com/logos-co/nomos/pull/1737
For a quick approach, we map the configurations of Prometheus and Grafana with configmaps:
# Prometheus configuration
kubectl -n nomos-testnet create configmap prom-config --from-file="$NOMOS_REPO_PATH/testnet/monitoring/prometheus.yml"
# Grafana configuration
kubectl -n nomos-testnet create configmap grafana-env --from-env-file="$NOMOS_REPO_PATH/testnet/monitoring/grafana/plugins.env"
kubectl -n nomos-testnet create configmap grafana-ini --from-file=grafana.ini="$NOMOS_REPO_PATH/testnet/monitoring/grafana/grafana.ini"
kubectl -n nomos-testnet create configmap grafana-provisioning --from-file=datasources.yaml="$NOMOS_REPO_PATH/testnet/monitoring/grafana/datasources.yaml" --from-file=dashboards.yml="$NOMOS_REPO_PATH/testnet/monitoring/grafana/dashboards.yml"
kubectl -n nomos-testnet create configmap grafana-dashboards --from-file="$NOMOS_REPO_PATH/testnet/monitoring/grafana/dashboards"
Then, we deploy the monitoring tools, cfgsync, and when it is ready, the executors and the nodes.
# Apply deployments
kubectl apply -f prometheus.yaml
kubectl rollout status --watch --timeout=30000s deployment/prometheus -n $NAMESPACE
kubectl apply -f grafana.yaml
kubectl rollout status --watch --timeout=30000s deployment/grafana -n $NAMESPACE
kubectl apply -f cfgsync.yaml
kubectl rollout status --watch --timeout=30000s deployment/cfgsync -n $NAMESPACE
kubectl apply -f nomos_executor.yaml
kubectl apply -f nomos_node.yaml
For also quick debugging, we replaced Loki for getting the logs, to just stdout changing the following configuration in cfgsync.yaml: