Description of problem: Meet below error when build with openshift/wildfly-101-centos7 image in a behind proxy cluster: [INFO] Downloading: https://repo1.maven.org/maven2/org/apache/maven/plugins/maven-resources-plugin/2.6/maven-resources-plugin-2.6.pom [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 02:07 min [INFO] Finished at: 2018-06-01T02:39:11+00:00 [INFO] Final Memory: 13M/102M [INFO] ------------------------------------------------------------------------ [ERROR] Plugin org.apache.maven.plugins:maven-resources-plugin:2.6 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin:jar:2.6: Could not transfer artifact org.apache.maven.plugins:maven-resources-plugin:pom:2.6 from/to central (https://repo1.maven.org/maven2): Connect to repo1.maven.org:443 [repo1.maven.org/151.101.200.209] failed: Connection timed out (Connection timed out) -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException Aborting due to error code 1 from mvn package error: build error: non-zero (13) exit code from openshift/wildfly-101-centos7@sha256:e6b024745274fc786155a5103fbe4913bbfe1d5c51a31bd7f634a08c3b012750 Version-Release number of selected component (if applicable): docker.io/openshift/wildfly-101-centos7 7503a354c0f5 How reproducible: always Steps to Reproduce: 1.Create a wildfly app oc new-app openshift/wildfly-101-centos7~https://github.com/danmcp/openshift-jee-sample.git -e AUTO_DEPLOY_EXPLODED=true 2. 3. Actual results: openshift-jee-sample-1 Source Git@51807be Failed (AssembleFailed) About an hour ago 2m14s Expected results: Build should succeed like in cluster which is NOT behind proxy. Additional info:
did you set "HTTP_PROXY_HOST" and "HTTP_PROXY_PORT" ? those are the variables the wildfly image uses to configure its maven proxy settings.
Is it possible to let wildfly image read the proxy setting in master-config? so that users don't need to define it manuallt.
> Is it possible to let wildfly image read the proxy setting in master-config? so that users don't need to define it manuallt. definitely not master-config. The global proxy settings for builds would come from the build defaulter/overrider plugin, which, when using ansible, do automatically get configured to set the cluster proxy settings. However they still will only set HTTP_PROXY/HTTPS_PROXY, so the wildfly image won't do anything with them today. The wildfly image would need to be updated to respect HTTP_PROXY/HTTPS_PROXY instead of(or in addition to) HTTP_PROXY_HOST/HTTP_PROXY_PORT. I can look at making that change.
Thanks for your reply, I will change this bug to a RFE bug to track this issue, ok?
PR: https://github.com/openshift-s2i/s2i-wildfly/pull/171
Ben,whether this change only apply to openshift/wildfly-130-centos7? But openshift/wildfly-130-centos7 also failed with below error: [ERROR] Plugin org.apache.maven.plugins:maven-resources-plugin:2.6 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin:jar:2.6: Could not transfer artifact org.apache.maven.plugins:maven-resources-plugin:pom:2.6 from/to central (https://repo1.maven.org/maven2): http://file.rdu.redhat.com: Name or service not known: Unknown host http://file.rdu.redhat.com: Name or service not known -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException Aborting due to error code 1 from mvn package error: build error: non-zero (13) exit code from openshift/wildfly-130-centos7@sha256:7e8d7d44402ce2a91f640e6d45563733e667a33ffc9f478b04b06d08a9e35606
Yes I only made the change in the 13.0 wildfly image. I think this is working correctly.. maven is now using your proxy as expected. However the container running maven presumably does not have access to the redhat network(or perhaps the VPN DNS settings) and thus can't resolve the proxy hostname you're using.
Out proxy address has port number 3128, actually, it should use http://file.rdu.redhat.com:3128 to download package.
you're getting an unknown host error, the port is irrelevant because it failed to resolve "file.rdu.redhat.com" as a valid hostname.
OK, moving this bug to be verified now.