Fix 19575: Docker events doesn't work with authorization plugin
To support the requirement of blocking the request after the daemon responded the authorization plugin use a `response recorder` that replay the response after the flow ends. This commit adds support for commands that hijack the connection and flushes data via the http.Flusher interface. This resolves the error with the event endpoint. Signed-off-by: Liron Levin <liron@twistlock.com>
This commit is contained in:
parent
80ef4bfbc0
commit
a903b6a9c8
3 changed files with 76 additions and 9 deletions
|
@ -116,7 +116,7 @@ func (ctx *Ctx) AuthZResponse(rm ResponseModifier, r *http.Request) error {
|
|||
}
|
||||
}
|
||||
|
||||
rm.Flush()
|
||||
rm.FlushAll()
|
||||
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue