Plugs on/off
This commit is contained in:
parent
6012d432c8
commit
136a40f1c3
2 changed files with 72 additions and 2 deletions
|
|
@ -15,6 +15,8 @@ async fn main() {
|
|||
let protected = Router::new()
|
||||
.route("/stats", get(routes::stats::get_stats))
|
||||
.route("/power", get(routes::power::get_power))
|
||||
.route("/power/{device}/on", post(routes::power::power_on))
|
||||
.route("/power/{device}/off", post(routes::power::power_off))
|
||||
.route(
|
||||
"/services/{service}/restart",
|
||||
post(routes::services::restart_service),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue