Document worker secret verification
This commit is contained in:
parent
c051e42c2e
commit
de2992ff63
2 changed files with 10 additions and 4 deletions
|
|
@ -167,7 +167,7 @@ pub async fn post_api_worker_status(
|
|||
let (work, abort_work) = {
|
||||
let mut guard = workers.lock().unwrap();
|
||||
guard.clean();
|
||||
if !guard.verify(&name, &request.secret) {
|
||||
if !guard.verify_secret(&name, &request.secret) {
|
||||
return Ok((StatusCode::UNAUTHORIZED, "invalid secret").into_response());
|
||||
}
|
||||
guard.update(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue