Skip to content

Commit

Permalink
swagger: add missing parameters
Browse files Browse the repository at this point in the history
Signed-off-by: Tom Deseyn <[email protected]>
  • Loading branch information
tmds committed Jan 27, 2021
1 parent c3b3984 commit d0dcdf2
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 1 deletion.
17 changes: 17 additions & 0 deletions pkg/api/server/register_containers.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,19 @@ func (s *APIServer) registerContainersHandlers(r *mux.Router) error {
// name: name
// type: string
// description: container name
// - in: body
// name: body
// description: Container to create
// schema:
// allOf:
// - $ref: "#/definitions/ContainerConfig"
// - type: object
// properties:
// HostConfig:
// $ref: "#/definitions/HostConfig"
// NetworkingConfig:
// $ref: "#/definitions/NetworkingConfig"
// required: true
// responses:
// 201:
// $ref: "#/responses/ContainerCreateResponse"
Expand Down Expand Up @@ -365,6 +378,10 @@ func (s *APIServer) registerContainersHandlers(r *mux.Router) error {
// type: boolean
// default: true
// description: Stream the output
// - in: query
// name: one-shot
// type: boolean
// default: false
// produces:
// - application/json
// responses:
Expand Down
35 changes: 34 additions & 1 deletion pkg/api/server/register_images.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,31 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error {
// type: string
// description: needs description
// - in: query
// name: repo
// description: the repository name for the created image
// type: string
// - in: query
// name: tag
// type: string
// description: needs description
// - in: query
// name: message
// description: commit message
// type: string
// - in: header
// name: X-Registry-Auth
// type: string
// description: A base64-encoded auth configuration.
// - in: body
// name: request
// name: inputImage
// schema:
// type: string
// description: Image content if fromSrc parameter was used
// - in: query
// name: platform
// description: Platform in the format os[/arch[/variant]]
// type: string
// default: ""
// responses:
// 200:
// $ref: "#/responses/ok"
Expand Down Expand Up @@ -423,6 +436,11 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error {
// name: changes
// type: string
// description: instructions to apply while committing in Dockerfile format
// - in: body
// name: containerConfig
// description: The container configuration
// schema:
// $ref: "#/definitions/ContainerConfig"
// produces:
// - application/json
// responses:
Expand Down Expand Up @@ -624,6 +642,21 @@ func (s *APIServer) registerImagesHandlers(r *mux.Router) error {
// description: |
// output configuration TBD
// (As of version 1.xx)
// - name: inputStream
// in: body
// description: "A tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
// schema:
// type: string
// format: binary
// - name: Content-type
// in: header
// type: string
// enum:
// - application/x-tar
// default: application/x-tar
// - name: X-Registry-Config
// in: header
// type: string
// produces:
// - application/json
// responses:
Expand Down
7 changes: 7 additions & 0 deletions pkg/api/server/register_networks.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,13 @@ func (s *APIServer) registerNetworkHandlers(r *mux.Router) error {
// type: string
// required: true
// description: the name of the network
// - in: query
// name: verbose
// type: boolean
// default: false
// - in: query
// name: scope
// type: string
// produces:
// - application/json
// responses:
Expand Down

0 comments on commit d0dcdf2

Please sign in to comment.