provision/docker/flatten.go: returning when flatten finds error