The command line hostbeat client for Windows, MacOS and Linux. Made with ๐ฆ Rust and ๐ love.
- Rust 1.79.0
- Cargo 1.79.0
This installation version is only for development purposes, be sure to have principal language and dev-tools installed: Rust and Cargo with the minimal version specified.
-
Clone the respository
git clone https://github.com/ruben69695/hostbeat.git
-
Build the project usign cargo cli tool
cargo build
-
Run the project
cargo run -- --version
This installation version is for production use, be sure to have installed the dependencies for each platform to be able to install the CLI tool.
To be able to use the installation script รฌnstall.sh
, is required to have installed the next dependencies:
- bash
- curl
- unzip
Execute the script รฌnstall.sh
-
Give execute permission
chmod u+x install.sh
-
Execute the installer
sudo ./install.sh
If it's the first time installing the tool, re-open a new terminal to be able to use it
To be able to use the installation script รฌnstall.ps1
, is required to have installed the next dependencies:
- powershell
Execute the script รฌnstall.ps1
in Windows, admin is required to make the installation, if is not executed as admin it will be elevated to do it automatically.
- Execute the installer
.\install.ps1
If it's the first time installing the tool, re-open a new terminal to be able to use it
- Parameters
-h | --help show help -v | --version show program version client config gets current stored configuration client config --get-token gets current stored token client config --get-url gets current stored url client config --get-interval gets current stored interval client config --get-monitoring gets current stored monitoring value client config --set-url sets a new url in the configuration file client config --set-token sets a new token in the configuration file client config --set-interval sets a new interval in the configuration file client config --set-monitoring sets value to enable or disable host cpu and memory monitoring in the configuration file client daemon send heartbeats as a daemon using the configuration file client daemon --use-url send heartbeats as a daemon using custom url, overrides file value client daemon --use-token send heartbeats as a daemon using custom token, overrides file value client daemon --use-interval send heartbeats as a daemon using custom interval, overrides file value client daemon --use-monitoring send heartbeats as a daemon enabling or disabling monitoring, overrides file value client send send one heartbeat using data from file client send --use-url send heartbeat to custom url, overrides file value client send --use-token send heartbeat with custom token, overrides file value client send --use-monitoring send heartbeat and include host cpu and memory data
- Usage
hostbeat client config --set-token mocktoken --set-interval 1.0 hostbeat client daemon hostbeat client send --use-token anothermocktoken
-
Adding platform targets if not added: MacOS, Linux, Windows
rustup target add aarch64-apple-darwin rustup target add x86_64-apple-darwin rustup target add x86_64-unknown-linux-musl rustup target add x86_64-pc-windows-gnu
-
Build release for every platform
-
Multiple way
cargo build --release --target=aarch64-apple-darwin --target=x86_64-apple-darwin --target=x86_64-unknown-linux-musl --target=x86_64-pc-windows-gnu
-
Individual way
cargo build --target=aarch64-apple-darwin --release cargo build --target=x86_64-apple-darwin --release cargo build --target=x86_64-unknown-linux-musl --release cargo build --target=x86_64-pc-windows-gnu --release
- Fedora 37 and MacOS Monterey
- Lapce 0.2.5
- Codium 1.74
- Linux
- MacOS (Apple Silicon and Intel)
- Windows