Unverified Commit 489495d0 authored by Med G's avatar Med G

resolve review comments

parent 493b35bd
......@@ -34,7 +34,7 @@ const (
var (
// BaseImage is the base image is used to spin up kic containers. it uses same base-image as kind.
BaseImage = fmt.Sprintf("gcr.io/k8s-minikube/kicbase:%[email protected]:%s", Version, baseImageSHA)
BaseImage = fmt.Sprintf("gcr.io/k8s-minikube/kicbase1:%[email protected]:%s", Version, baseImageSHA)
// BaseImageFallBack the fall back of BaseImage in case gcr.io is not available. stored in github packages https://github.com/kubernetes/minikube/packages/206071
// github packages docker does _NOT_ support pulling by sha as mentioned in the docs:
// https://help.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-docker-for-use-with-github-packages
......
......@@ -16,7 +16,7 @@ limitations under the License.
package image
// ErrNeedsLogin is thrown when regsitery needs login (a general)
// ErrNeedsLogin is thrown when regsitry needs login (a general)
var ErrNeedsLogin error
// ErrGithubNeedsLogin is thrown when user needs to login to github to use the fall back image
......
......@@ -130,12 +130,14 @@ func waitDownloadKicArtifacts(g *errgroup.Group) {
if err != nil {
if errors.Is(err, image.ErrGithubNeedsLogin) {
glog.Warningf("Error downloading kic artifacts: %v", err)
out.T(out.Connectivity, "Unfortunately, could not download the base image {{.image_name}} ", out.V{"image_name": strings.Split(kic.BaseImage, "@")[0]})
out.WarningT("In order to use the fall back image, you need to log into to the github packages registry")
out.T(out.Documentation, "https://help.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-docker-for-use-with-github-packages#authenticating-to-github-packages")
out.ErrT(out.Connectivity, "Unfortunately, could not download the base image {{.image_name}} ", out.V{"image_name": strings.Split(kic.BaseImage, "@")[0]})
out.WarningT("In order to use the fall back image, you need to log in to the github packages registry")
out.T(out.Documentation, `Please visit the following link for documentation around this:
https://help.github.com/en/packages/using-github-packages-with-your-projects-ecosystem/configuring-docker-for-use-with-github-packages#authenticating-to-github-packages
`)
}
if errors.Is(err, image.ErrGithubNeedsLogin) || errors.Is(err, image.ErrNeedsLogin) {
exit.UsageT(`Please either authenticate the registry or use --base-image option to use a different registry.`)
exit.UsageT(`Please either authenticate to the registry or use --base-image flag to use a different registry.`)
} else {
glog.Errorln("Error downloading kic artifacts: ", err)
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment