Closed winkidzz closed 6 years ago
Here is minishift having same error
From openshift web console:
An error occurred connecting to the server. Failed to get imagestreamtags/image.openshift.io/v1/wildfly:12.0 (status 404) Refresh
from oc command line
C:\minishift>oc new-app centos/ruby-22-centos7~https://github.com/openshift/ruby -ex.git -loglevel=8 W1008 10:31:08.394244 26748 dockerimagelookup.go:233] Docker registry lookup f ailed: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker. io on 10.0.2.3:53: no such host error: unable to locate any images in image streams, local docker images with na me "centos/ruby-22-centos7"
@openshift/sig-developer-experience
W1005 15:21:17.153512 26905 dockerimagelookup.go:233] Docker registry lookup failed: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.2.217.17:53: no such host
If you want oc new-app to use a proxy to talk to docker.io, you need to set HTTP_PROXY/HTTPS_PROXY in the environment new-app is running under so it can reach docker.io. That is unrelated to the proxy arguments you are passing to new-app.
error: no tags found on matching image stream: "openshift/php" The image stream "openshift/php" exists, but it has no tags.
If you want new-app to use an imagestream, then you need to ensure your imagestreams are actually present+imported in your cluster, so you'll need to investigate why the php imagestream has not successfully imported tags.
Perfect! That was my understanding. The minishift is recreated with below proxy variables.
minishift.exe --vm-driver=virtualbox --docker-env HTTP_PROXY=http://user:pwd@host.company.com:80 --docker-env NO_PROXY=172.30.1.1 --docker-env HTTPS_PROXY=http://user:pwd@host.company.com:80 --http-proxy=http://user:pwd@host.company.com:80 --https-proxy=http://user:pwd@host.company.com:80 --iso-url b2d start
Here is my environment which holds both the proxy values.
docker@minishift:~$ env HTTPS_PROXY=http://user:mypassischaracter@host.company.com:80 no_proxy=localhost,127.0.0.1,172.30.1.1,192.168.99.100,192.168.99.1 SSH_CLIENT=10.0.2.2 60256 22 MAIL=/var/mail/docker USER=docker SHLVL=1 HOME=/home/docker NO_PROXY=localhost,127.0.0.1,172.30.1.1,192.168.99.100,192.168.99.1 SSH_TTY=/dev/pts/0 PAGER=less -EM PS1=\u@\h:\w\$ ENV=/home/docker/.ashrc BACKUP=1 https_proxy=http://user:mypassischaracter@host.company.com:80 LOGNAME=docker http_proxy=http://user:mypassischaracter@host.company.com:80 TERM=xterm PATH=/home/docker/.local/bin:/usr/local/sbin:/usr/local/bin:/apps/bin:/usr/sbin:/usr/bin:/sbin:/bin G_FILENAME_ENCODING=iso8859-1 LANG=C MANPAGER=less -isR SHELL=/bin/sh FLWM_TITLEBAR_COLOR=58:7D:AA PWD=/home/docker SSH_CONNECTION=10.0.2.2 60256 10.0.2.15 22 HTTP_PROXY=http://user:mypassischaracter@host.company.com:80 EDITOR=vi
The oc-newapp is notable to use this. I had this working last year with minikube unfortunately with latest version I am stuck. Please let me know if you would like more details or dumps and i would be happy to provide.
I have the same problem. I am with win10+hyperv+nat behind a corporate proxy.
Does anyone know how to fix the problem?
new-app uses nothing specific, standard golang libs which respect the traditional http/https proxy env vars.
the issue you are hitting is cluster-side. The imagestreamimport failed within the cluster because the cluster could not reach docker.io to do the import.
I0919 15:46:10.958038 5572 request.go:897] Response Body: {"kind":"ImageStreamImport","apiVersion":"image.openshift.io/v1","metadata":{"name":"newapp","namespace":"myproject","selfLink":"/apis/image.openshift.io/v1/namespaces/myproject/imagestreamimports/newapp","uid":"d632ab06-dae3-11e9-8b28-080027d1cfc5","creationTimestamp":"2019-09-19T13:46:09Z"},"spec":{"import":false,"images":[{"from":{"kind":"DockerImage","name":"nodejs"},"importPolicy":{},"referencePolicy":{"type":"Source"}}]},"status":{"images":[{"status":{"metadata":{},"status":"Failure","message":"Internal error occurred: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.0.2.3:53: no such host","reason":"InternalError","details":{"causes":[{"message":"Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.0.2.3:53: no such host"}]},"code":500},"tag":"latest"}]}}
I0919 15:46:10.960038 5572 dockerimagelookup.go:227] image import failed: image.ImageImportStatus{Tag:"latest", Status:v1.Status{TypeMeta:v1.TypeMeta{Kind:"", APIVersion:""}, ListMeta:v1.ListMeta{SelfLink:"", ResourceVersion:"", Continue:""}, Status:"Failure", Message:"Internal error occurred: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.0.2.3:53: no such host", Reason:"InternalError", Details:(*v1.StatusDetails)(0xc04373bda0), Code:500}, Image:(*image.Image)(nil)}
W0919 15:46:10.967038 5572 dockerimagelookup.go:233] Docker registry lookup failed: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.0.2.3:53: no such host
F0919 15:46:10.967538 5572 helpers.go:119] error: no tags found on matching image stream: "openshift/nodejs"
The oc new image throws lookup error. The calls to pull image is not going through proxy but using guest dns.
oc new-app https://github.com/sclorg/cakephp-ex --build-env HTTP_PROXY=http://10.0.2.2:3128 --build-env HTTPS_PROXY=http://10.0.2.2:3128 warning: Cannot check if git requires authentication. W1005 15:21:17.153512 26905 dockerimagelookup.go:233] Docker registry lookup failed: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 10.2.217.17:53: no such host error: no tags found on matching image stream: "openshift/php"
The image stream "openshift/php" exists, but it has no tags.
Use --allow-missing-imagestream-tags to use this image stream
Version
[root@localhost vagrant]# docker version Client: Version: 1.13.1 API version: 1.26 Package version: docker-1.13.1-75.git8633870.el7.centos.x86_64 Go version: go1.9.4 Git commit: 8633870/1.13.1 Built: Fri Sep 28 19:45:08 2018 OS/Arch: linux/amd64
Server: Version: 1.13.1 API version: 1.26 (minimum version 1.12) Package version: docker-1.13.1-75.git8633870.el7.centos.x86_64 Go version: go1.9.4 Git commit: 8633870/1.13.1 Built: Fri Sep 28 19:45:08 2018 OS/Arch: linux/amd64 Experimental: false
[root@localhost vagrant]# oc version oc v3.10.0+0c4577e-1 kubernetes v1.10.0+b81c8f8 features: Basic-Auth GSSAPI Kerberos SPNEGO
Server https://10.25.82.191:8443 openshift v3.10.0+fd501dd-48 kubernetes v1.10.0+b81c8f8
Steps To Reproduce
Vagrant.configure("2") do |config|
config.vm.box = "centos/7" config.vm.box_download_insecure = true config.vm.provision :shell, path: "bootstrap.sh" config.vm.network "public_network"
config.vm.synced_folder ".", "/guest_host", disabled: false
config.vm.provider "virtualbox" do |vb|
end if Vagrant.has_plugin?("vagrant-proxyconf") config.proxy.http = "http://10.0.2.2:3128" config.proxy.https = "http://10.0.2.2:3128" config.proxy.no_proxy = "localhost,10.25.82.191,,127.0.0.,10.,192.168.,172.,*.company.com,localhost.localdomain,172.30.1.1"
oc cluster up --public-hostname=10.25.82.191 --http-proxy 'http://10.0.2.2:3128' --https-proxy 'http://10.0.2.2:3128' --no-proxy '172.17.0.0/16,localhost,.company.com,127.0.0.,10.,192.168.,172.*,localhost.localdomain,172.30.1.1'
OpenShift server started.
The server is accessible via web console at: https://10.25.82.191:8443
The image stream "openshift/php" exists, but it has no tags.
Use --allow-missing-imagestream-tags to use this image stream
Current Result
error
Expected Result
new application created in os