diff --git a/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/Images.hs b/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/Images.hs index 81c22ac2..5fcec413 100644 --- a/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/Images.hs +++ b/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/Images.hs @@ -87,15 +87,24 @@ loadImage' kcc@(KubernetesClusterContext {kubernetesClusterType, kubernetesClust case kubernetesClusterType of (KubernetesClusterKind {..}) -> Kind.loadImage kindBinary kindClusterName image env - (KubernetesClusterMinikube {..}) -> do - image' <- Minikube.loadImage minikubeBinary kubernetesClusterName minikubeFlags image + (KubernetesClusterMinikube {..}) -> + -- Don't pass minikubeFlags; see comment above. + Minikube.loadImage minikubeBinary kubernetesClusterName [] image -- Because of the possible silent failure in "minikube image load", confirm that this -- image made it onto the cluster. - loadedImages <- Set.toList <$> getLoadedImages' kcc - loadedImages `shouldContain` [image'] - - return image' + -- At the moment this approach doesn't work, because if you do + -- "minikube image load busybox:1.36.1-musl" + -- followed by + -- "minikube image ls", + -- the result contains "docker.io/library/busybox:1.36.1-musl". + -- Where did the docker.io/library/ come from? Need to understand this before we can + -- check this properly. + -- + -- image' <- Minikube.loadImage minikubeBinary kubernetesClusterName minikubeFlags image + -- loadedImages <- Set.toList <$> getLoadedImages' kcc + -- loadedImages `shouldContain` [image'] + -- return image' -- | Helper to introduce a list of images into a Kubernetes cluster. -- Stores the list of transformed image names under the "kubernetesClusterImages" label. diff --git a/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/MinikubeCluster/Images.hs b/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/MinikubeCluster/Images.hs index 20ae9479..8088d070 100644 --- a/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/MinikubeCluster/Images.hs +++ b/sandwich-contexts-kubernetes/lib/Test/Sandwich/Contexts/Kubernetes/MinikubeCluster/Images.hs @@ -80,7 +80,7 @@ loadImage minikubeBinary clusterName minikubeFlags image = do let args = ["image", "load", toLoad , "--profile", toString clusterName - , "--logtostderr=true", "--v=2" + , "--logtostderr=true", "--v=1" , [i|--daemon=#{A.encode daemon}|] ] <> extraFlags