IsServerRunning reports whether a server answers on the configured address.
(cfg *config.Config)
| 274 | |
| 275 | // IsServerRunning reports whether a server answers on the configured address. |
| 276 | func IsServerRunning(cfg *config.Config) bool { |
| 277 | return portHeld(cfg.Host, cfg.Port) |
| 278 | } |
| 279 | |
| 280 | // Two questions, two probes (TASK-3620). The old single probe was an HTTP GET |
| 281 | // of /health that required a 200, and it was wrong both ways: |