[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] proxy question

Hey David!

Perhaps this reference will help?
http://wiki.eclipse.org/Hudson#Configuring_a_proxy_for_the_p2_director

Not sure how this "fits in" with tycho-eclipserun-plugin ... but it
explains how p2 doesn't use -Dhttp.proxyHost, etc.

Tycho-eclipserun-plugin might provide its own methods/techniques for
setting the Eclipse network preferences (I'm not familiar with it, hate
to admit).

That pointer was very helpful, thank you very very much for that!!! Much appreciated!!!

I ended up adding this to my pom.xml file (before I execute the tycho-eclipserun-plugin), in case anybody else needs this as well.

Cheers,
-Martin


<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>configure-proxies-for-eclipserun</id>
<phase>package</phase>
<configuration>
<target>
<touch file="${project.build.directory}/work/configuration/.settings/org.eclipse.core.net.prefs" mkdirs="true"/>

<propertyfile file="${project.build.directory}/work/configuration/.settings/org.eclipse.core.net.prefs">
<entry key="eclipse.preferences.version" value="1"/>
<entry key="nonProxiedHosts" value="${http.nonProxyHosts}"/>
<entry key="org.eclipse.core.net.hasMigrated" value="true"/>
<entry key="proxyData/HTTP/hasAuth" value="false"/>
<entry key="proxyData/HTTP/host" value="${http.proxyHost}"/>
<entry key="proxyData/HTTP/port" value="${http.proxyPort}"/>
<entry key="systemProxiesEnabled" value="false"/>
</propertyfile>
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>








From: Martin Lippert <lippert@xxxxxxx> To: P2 developer discussions <p2-dev@xxxxxxxxxxx>, Date: 08/29/2012 12:09 PM Subject: [p2-dev] proxy question Sent by: p2-dev-bounces@xxxxxxxxxxx ------------------------------------------------------------------------



Hey!

I am trying to use the tycho-eclipserun-plugin at the moment in one of
our builds, which executes the p2 director application. Since the build
is running behind a proxy (just a simple http proxy, no authentication
required), I need to set those proxy settings to let the director find
the given repositories.

Since this is part of our CI builds, I cannot manually configure
preferences or so, I need to execute a command line with parameters.

I tried to just set "-Dhttp.proxyHost" etc. without success

I tried to set
"-Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient",

that switches to a JDK Http connection, but still ignores my settings to
-Dhttp.proxyHost" etc.

I always see these messages:
!MESSAGE System property http.proxyHost has been set to proxy.xyz.com by
an external source. This value will be overwritten using the values from
the preferences

(where xyz is my real proxy name)

Are the system properties deleted or overridden with something else, so
that my JDK Http connection is not able to use my settings?

I also tried to set -Dhttpclient.proxy-host=xyz -Dhttpclient.proxy-port=nnn
but that doesn't work either.

I am kind of stuck here and hope very much that you can help me!!!

Thanks a lot!!!
-Martin

_______________________________________________
p2-dev mailing list
p2-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/p2-dev




_______________________________________________ p2-dev mailing list p2-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/p2-dev