Files
MultiSshDeployer/README.md

2.0 KiB

MultiSshDeployer

This tool provides a straightforward way to execute multiple Bash commands on various devices.

How to use

  1. Launch a terminal and navigate to this directory.
  2. Execute npm install to install all necessary dependencies.
  3. Enter npm start to generate a new config.json file within the directory.
  4. Modify the config.json file to configure your deployment settings.
  5. Run npm start once more to initiate the deployment of Bash commands.
  6. The outputs from each device will be saved in the output folder.

Configuration

This tool features an easy-to-use configuration that can be modified through the config.json file. If the file is not present, run npm start to generate it. Below is an example of a typical configuration:

{
    "addresses": ["192.168.0.100", "192.168.0.101:80"],
    "username": "username",
    "password": "password",
    "payload": [
        "ls -l",
        "reboot",
        "exit"
    ]
}
Property Type Description
addresses string[] This is a list of device addresses. If no port is specified, it will default to port 22.
username string Represents the SSH username.
password string Indicates the SSH password.
payload string[] A list of Bash commands to be executed.

Output

While running the tool, all SSH output will be displayed in the console and saved to a log file within the output directory. Each log file will be named using the corresponding device address. Please note that if a log file with the same name already exists in the output directory, it will be overwritten!