This Ansible playbook provides a complete automated setup for a GenLayer Validator Node on Linux systems, ensuring a secure, repeatable, and production-ready installation in just a few commands.
- Automated OS dependency installation (Docker, Docker Compose, curl)
- Download and extraction of GenLayer node software
- Comprehensive configuration file generation
- Secure validator key generation and backup
- LLM backend activation based on API keys
- WebDriver container provisioning with Docker Compose
- Systemd service management for automatic startup
- Validator address banner output
- Operating System: Linux (Ubuntu/Debian recommended)
- Privileges: Root or
sudo
access - Software: Docker, Docker Compose, Ansible
- Network: Outbound access to GenLayer and ZKSync endpoints
Save deploy.yml
(the playbook) to your working directory.
In deploy.yml
, locate the vars:
section and customize values:
- GenLayer release version (
genlayer_version
) - Node password and backup passphrase
- GenLayer RPC endpoints (
zksync_rpc_url
,zksync_ws_url
) - LLM API keys, if backends required
Open a terminal and run:
sudo apt update
sudo apt install docker.io docker-compose curl ansible -y
sudo systemctl enable --now docker
Add your user to the Docker group for non-root container management (optional):
sudo usermod -aG docker $USER
Log out and log back in again to apply group changes.
Run the playbook, targeting your machine (localhost):
ansible-playbook -i localhost, -c local deploy.yml
This launches the entire deployment process from software fetch to service activation.
- Node binaries and dependencies are installed.
config.yaml
is generated with all specified options.- A validator key and encrypted backup are created.
- LLM backends are enabled or disabled as per your API keys.
- WebDriver container starts automatically.
- A systemd service ensures the node runs and restarts on boot.
- The validator address is printed in a highlighted banner.
Check node health (should show "active"):
sudo systemctl status genlayer-node.service
View live logs:
sudo journalctl -u genlayer-node.service -f
Access Prometheus metrics:
curl http://localhost:9153/metrics