An Ansible playbook for restake.app on Cosmos.
Ideally ansible should be installed via pip, the package installer for python.
This README assumes that you've already installed debian
or ubuntu
onto the target environment/s.
- Install the required git submodule dependencies:
git submodule update --init
- Install the ansible
community.general
collection:
ansible-galaxy collection install community.general
- Rename the
hosts.example
file ininventory/
tohosts
:
cp inventory/hosts.example inventory/hosts
-
Edit the
inventory/hosts
and add the IP addresses of your restake node/s. -
Rename the
networks.local.json.example
file inroles/restake/files/
tonetworks.local.json
:
cp roles/restake/files/networks.local.json.example roles/restake/files/networks.local.json
- Edit the file
roles/restake/files/networks.local.json
and update with the networks you will offer restake on. For more information, see here.
To setup a new restake node:
PASSWORD='<password>' \
DD_API_KEY=<dd_api_key> \
MNEMONIC=<mnemonic> \
PROVIDER=<provider> \
TARGET=<target> \
make setup
where:
Param | Description | Required |
---|---|---|
<password> |
The password for the default user that gets created. | true |
<dd_api_key> |
The DataDog API key. | false |
<mnemonic> |
The mnemonic phrase of the restake funding wallet. | true |
<provider> |
The provider being used (mevspace or ovhcloud ). |
false |
<target> |
The IP address of the host to run the playbook against (all hosts will be configured if not provided). | false |
e.g.:
DD_API_KEY=0gD04PXCnLk0CYNHdamJ7lylKs5uMZkJ \
MNEMONIC='some words that make up my mnemonic' \
PROVIDER=ovhcloud \
TARGET=1.2.3.4 \
make setup
Whenever you want to update the networks you offer restake on, simply update the file roles/restake/files/networks.local.json
accordingly and run:
TARGET=<target> \
make update
where:
Param | Description | Required |
---|---|---|
<target> |
The IP address of the host to run the playbook against (all hosts will be configured if not provided). | false |
e.g.:
TARGET=1.2.3.4 \
make update