mirror of https://github.com/docker/cli.git
Add omitempty on compose config top-level types
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
This commit is contained in:
parent
7c7c299eee
commit
f05ab2b1fb
|
@ -32,10 +32,6 @@ services:
|
|||
image: bar
|
||||
foo:
|
||||
image: foo
|
||||
networks: {}
|
||||
volumes: {}
|
||||
secrets: {}
|
||||
configs: {}
|
||||
`), s.ComposeFile)
|
||||
}
|
||||
|
||||
|
|
|
@ -73,10 +73,10 @@ type Config struct {
|
|||
Filename string `yaml:"-"`
|
||||
Version string
|
||||
Services Services
|
||||
Networks map[string]NetworkConfig
|
||||
Volumes map[string]VolumeConfig
|
||||
Secrets map[string]SecretConfig
|
||||
Configs map[string]ConfigObjConfig
|
||||
Networks map[string]NetworkConfig `yaml:",omitempty"`
|
||||
Volumes map[string]VolumeConfig `yaml:",omitempty"`
|
||||
Secrets map[string]SecretConfig `yaml:",omitempty"`
|
||||
Configs map[string]ConfigObjConfig `yaml:",omitempty"`
|
||||
Extras map[string]interface{} `yaml:",inline"`
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue