Piotr Żygieło <piotr.zygi...@gmail.com> 于2020年5月31日周日 下午7:21写道: > > > 2. Then I try to use the environment variable based method to set the > > proxy but failed to confirm it. See the following for more info: > > > > > > Use the proxy setting directly in maven's command options: > > Or define them in the MAVEN_OPTS environment variable: > > > > As you can see, in this case, it seems the http proxy passed as > > command options or set by environment variable doesn't picked up by > > maven at all. Any hints for this problem? > > https://docs.oracle.com/javase/7/docs/technotes/guides/net/proxies.html > > Just guessing. > The -D options you use are intended and consumed by JVM itself.
Greping in the maven installation directory also confirms the above comment: $ grep -inR 'MAVEN_OPTS' . | grep -i java ./3.6.3/bin/mvnDebug:26:# MAVEN_OPTS (Optional) Java runtime options used when Maven is executed. > That's why socks proxy works when configured with > socksProxyHost/socksProxyPort, because maven even doesn't know about > traffic being proxied. > > P. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > -- Hongyi Zhao <hongyi.z...@gmail.com> --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org