Crates.io | server-runner |
lib.rs | server-runner |
version | 1.4.0 |
source | src |
created_at | 2023-05-29 19:15:43.482113 |
updated_at | 2024-04-07 16:36:43.303715 |
description | Runs servers, checks for HTTP 200 and runs a command when all servers are up and running |
homepage | https://github.com/webcodr/server-runner |
repository | https://github.com/webcodr/server-runner |
max_upload_size | |
id | 877272 |
size | 64,022 |
Server Runner is a little Rust programm to run multiple web servers, check until all servers are ready via a URL that returns HTTP 200 und runs a command when all servers are ready.
Currently Server Runner is only available via Cargo. It will be also available via NPM in the near future, since NPM is available on almost any OS out there and it's much easier to publish than to many other package managers.
cargo install server-runner
Example
servers:
- name: "My web server"
url: "http://localhost:8080"
command: "node webserver.js"
command: "node cypress"
server-runner -c config.yaml
Default name of the config file is servers.yaml
in your current working directory.
Server Runner will attempt to check a server's status up to ten times with one second between each attempt. If a server is not responding with HTTP 200 after that, Server Runner will shutdown all servers and exit.