Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use gcr.io and minikube in China. #51

Open
WyattJia opened this issue Sep 10, 2018 · 1 comment
Open

Use gcr.io and minikube in China. #51

WyattJia opened this issue Sep 10, 2018 · 1 comment

Comments

@WyattJia
Copy link
Owner

WyattJia commented Sep 10, 2018

As you know, gcr.io is blocked in China.Here is a solution to reslove this problem.

Summarize how to fix it

  • Option 1:
    download the images from gcr.io and other docker registry one by one manually.
  • Option 2:
    setup shadowsocks and at shadowsock client, you need to enable it to allow other device connect to it.
    then
minikube start --docker-env HTTP_PROXY=http://<your local network ip>:<ss proxy port> --docker-env HTTPS_PROXY=https://<your local network ip>:<ss proxy port>

and

export no_proxy=$no_proxy,$(minikube ip)
Now you need to wait to see all images are downloaded successfully.
minikube ssh -- docker images
output like below but the images vary as you use different version of minikube.

then

$ minikube ssh -- docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
k8s.gcr.io/kubernetes-dashboard-amd64 v1.8.1 e94d2f21bc0c 5 months ago 121MB
gcr.io/google-containers/kube-addon-manager v6.5 d166ffa9201a 6 months ago 79.5MB
gcr.io/k8s-minikube/storage-provisioner v1.8.1 4689081edb10 7 months ago 80.8MB
k8s.gcr.io/k8s-dns-sidecar-amd64 1.14.5 fed89e8b4248 8 months ago 41.8MB
k8s.gcr.io/k8s-dns-kube-dns-amd64 1.14.5 512cd7425a73 8 months ago 49.4MB
k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64 1.14.5 459944ce8cc4 8 months ago 41.4MB
wardviaene/k8s-demo 2 a589ef0d2b4e 19 months ago 651MB
gcr.io/google_containers/pause-amd64 3.0 99e59f495ffa 2 years ago 747kB

By the way , I have one more solution.We can use Docker hub autobuild with Github Integrate. You can read my kube-apiserver-amd64 and Docker Hub Docs

@WyattJia WyattJia changed the title gcr.io and minikube Use gcr.io and minikube in China. Sep 17, 2018
@WyattJia WyattJia pinned this issue Jan 31, 2019
@WyattJia WyattJia unpinned this issue Jan 31, 2019
@liudonghua123
Copy link

I tried use --docker-env HTTP_PROXY=http://<your local network ip>:<ss proxy port> --docker-env HTTPS_PROXY=https://<your local network ip>:<ss proxy port>, but it did not work. After some struggling, I use the customized minikube from http://kubernetes.oss-cn-hangzhou.aliyuncs.com/minikube/releases/v1.2.0/minikube-windows-amd64.exe?spm=a2c4e.11153940.0.0.7dd54cecjlFs90&file=minikube-windows-amd64.exe, then it works. More details can be found on https://yq.aliyun.com/articles/221687.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants