Skip to content

Commit

Permalink
api: move types.Volume to volume.Volume
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
  • Loading branch information
thaJeztah committed Apr 21, 2022
1 parent 1a0c15a commit f19ef20
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 4 deletions.
14 changes: 14 additions & 0 deletions api/types/deprecated.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package types // import "github.com/docker/docker/api/types"

import "github.com/docker/docker/api/types/volume"

// Volume volume
//
// Deprecated: use github.com/docker/docker/api/types/volume.Volume
type Volume = volume.Volume

// VolumeUsageData Usage details about the volume. This information is used by the
// `GET /system/df` endpoint, and omitted in other endpoints.
//
// Deprecated: use github.com/docker/docker/api/types/volume.VolumeUsageData
type VolumeUsageData = volume.VolumeUsageData
2 changes: 1 addition & 1 deletion api/types/volume.go → api/types/volume/volume.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package types
package volume

// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command
Expand Down
10 changes: 7 additions & 3 deletions hack/generate-swagger-api.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,13 @@ swagger generate model -f api/swagger.yaml \
-n IdResponse \
-n ImageDeleteResponseItem \
-n ImageSummary \
-n Plugin -n PluginDevice -n PluginMount -n PluginEnv -n PluginInterfaceType \
-n Plugin \
-n PluginDevice \
-n PluginMount \
-n PluginEnv \
-n PluginInterfaceType \
-n Port \
-n ServiceUpdateResponse \
-n Volume
-n ServiceUpdateResponse

swagger generate model -f api/swagger.yaml \
-t api -m types/container --skip-validator -C api/swagger-gen.yaml \
Expand All @@ -20,6 +23,7 @@ swagger generate model -f api/swagger.yaml \

swagger generate model -f api/swagger.yaml \
-t api -m types/volume --skip-validator -C api/swagger-gen.yaml \
-n Volume \
-n VolumeCreateOptions

swagger generate operation -f api/swagger.yaml \
Expand Down

0 comments on commit f19ef20

Please sign in to comment.