Ver Fonte

only check volume mounts for updated config

Signed-off-by: Nicolas De Loof <[email protected]>
Nicolas De Loof há 1 ano atrás
pai
commit
038c81f34e
1 ficheiros alterados com 3 adições e 0 exclusões
  1. 3 0
      pkg/compose/convergence.go

+ 3 - 0
pkg/compose/convergence.go

@@ -384,6 +384,9 @@ func checkExpectedNetworks(expected types.ServiceConfig, actual moby.Container,
 func checkExpectedVolumes(expected types.ServiceConfig, actual moby.Container, volumes map[string]string) bool {
 func checkExpectedVolumes(expected types.ServiceConfig, actual moby.Container, volumes map[string]string) bool {
 	// check container's volume mounts and search for the expected ones
 	// check container's volume mounts and search for the expected ones
 	for _, vol := range expected.Volumes {
 	for _, vol := range expected.Volumes {
+		if vol.Type != string(mmount.TypeVolume) {
+			continue
+		}
 		id := volumes[vol.Source]
 		id := volumes[vol.Source]
 		found := false
 		found := false
 		for _, mount := range actual.Mounts {
 		for _, mount := range actual.Mounts {