diff --git a/cosmovisor/Readme.md b/cosmovisor/Readme.md new file mode 100644 index 0000000..4e949b4 --- /dev/null +++ b/cosmovisor/Readme.md @@ -0,0 +1,107 @@ +# Cosmos Node Installer with Cosmovisor Support + +A Bash script to automate the setup of Cosmos SDK-based nodes with optional Cosmovisor integration. + +This tool simplifies the setup process by configuring environment variables, installing Cosmovisor, and creating a systemd service to manage your node binary. + +--- + +## πŸš€ Features + +- Cosmos SDK node setup +- Cosmovisor installer (version selection) +- systemd service generator +- Automated environment variable setup +- Minimal manual config + +--- + +## πŸ“¦ Prerequisites + +- **Golang installed** (`>=1.17`) +- GitHub project details for the Cosmos-based chain you want to install +- `go` in your system `PATH` +- Superuser (`sudo`) access + +--- + +## πŸ“ Script Arguments + +| Flag | Description | +|------|-------------| +| `-p` | Path to your Cosmos binary (e.g., `/home/user/go/bin/desmos`) | +| `-b` | Binary name (e.g., `desmos`) | +| `-c` | Configuration folder name (e.g., `desmos`) | +| `-s` | Optional Cosmovisor version (e.g., `v1.6.0`) | + +--- + +## βš™οΈ Example Usage + +```bash +bash install.sh -p /root/go/bin/desmos -b desmos -c desmos -s v1.6.0 +``` + +## This will: + +- Set required environment variables for `DAEMON_NAME` and `DAEMON_HOME` +- Install Cosmovisor (interactive version selection) +- Initialize Cosmovisor with your provided binary +- Create a systemd service for automatic node management +- Configure `.profile` for persistence across sessions + +--- + +## πŸ›  Cosmovisor Version Options +The script prompts you to choose one of: +- `v1.6.0 (Recommended)` +- `v1.3.0` +- `latest` + +You can also predefine a version using `-s` flag to skip the prompt. + +--- + +## πŸ” What It Does Under the Hood +- Runs [Cosmos SDK’s Cosmovisor](https://docs.cosmos.network/master/run-node/cosmovisor.html) +- Sets up `~/.profile` with all necessary `DAEMON_*` environment variables +- Validates `cosmovisor` binary presence or installs it via `go install` +- Automatically reloads `systemd` and enables the service + +--- + +## πŸ“„ Output Example +``` +:: Cosmovisor installed... +:: Cosmosvisor initialised successfully. +:: Cosmovisor service installed. +``` +--- + +## 🧰 Maintainers & Contributors +This tool is maintained by Staketab. Contributions to improve the automation and documentation are welcome. + +If you're a technical writer or developer looking to improve this project’s usability, open a pull request or submit an issue. + +--- + +## πŸͺͺ License +MIT License – see `[LICENSE]` file for details. + +--- + +## 🀝 Contributing +Feel free to open PRs to: +* Improve documentation +* Support more Cosmos SDK chains +* Add testing/validation steps +* Refactor functions for portability + +--- + +## πŸ“¬ Feedback +Found a bug or want to suggest an improvement? +Open an issue [here](https://github.com/Staketab/node-tools/issues) or start a discussion. + +--- +