summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorBrent Baude <bbaude@redhat.com>2020-03-11 09:25:57 -0500
committerBrent Baude <bbaude@redhat.com>2020-03-11 09:25:57 -0500
commit216a6091d0541285ba2607dbd8aa8c216e27323f (patch)
tree0acbb9598a059f6e52fa77dcfa070d9fb8cf0a20 /pkg
parent087fc79233f647cdbd4b4bc409c3bd8b02aedb13 (diff)
downloadpodman-216a6091d0541285ba2607dbd8aa8c216e27323f.tar.gz
podman-216a6091d0541285ba2607dbd8aa8c216e27323f.tar.bz2
podman-216a6091d0541285ba2607dbd8aa8c216e27323f.zip
[CI:DOCS]Add libpod event endpoint
add an endpoint for events on the libpod side of the house. Signed-off-by: Brent Baude <bbaude@redhat.com>
Diffstat (limited to 'pkg')
-rw-r--r--pkg/api/server/register_events.go31
1 files changed, 29 insertions, 2 deletions
diff --git a/pkg/api/server/register_events.go b/pkg/api/server/register_events.go
index 96ba4596e..b0f403709 100644
--- a/pkg/api/server/register_events.go
+++ b/pkg/api/server/register_events.go
@@ -11,8 +11,8 @@ func (s *APIServer) registerEventsHandlers(r *mux.Router) error {
// swagger:operation GET /events system getEvents
// ---
// tags:
- // - system
- // summary: Returns events filtered on query parameters
+ // - system (compat)
+ // summary: Get events
// description: Returns events filtered on query parameters
// produces:
// - application/json
@@ -37,5 +37,32 @@ func (s *APIServer) registerEventsHandlers(r *mux.Router) error {
r.Handle(VersionedPath("/events"), s.APIHandler(compat.GetEvents)).Methods(http.MethodGet)
// Added non version path to URI to support docker non versioned paths
r.Handle("/events", s.APIHandler(compat.GetEvents)).Methods(http.MethodGet)
+ // swagger:operation GET /libpod/events system libpodGetEvents
+ // ---
+ // tags:
+ // - system
+ // summary: Get events
+ // description: Returns events filtered on query parameters
+ // produces:
+ // - application/json
+ // parameters:
+ // - name: since
+ // type: string
+ // in: query
+ // description: start streaming events from this time
+ // - name: until
+ // type: string
+ // in: query
+ // description: stop streaming events later than this
+ // - name: filters
+ // type: string
+ // in: query
+ // description: JSON encoded map[string][]string of constraints
+ // responses:
+ // 200:
+ // description: returns a string of json data describing an event
+ // 500:
+ // "$ref": "#/responses/InternalError"
+ r.Handle(VersionedPath("/events"), s.APIHandler(compat.GetEvents)).Methods(http.MethodGet)
return nil
}