I simply have a mirror in my settings.xml, which is in my $HOME/.m2
directory.
<settings>
<mirrors>
<mirror>
<id>lsu.edu</id>
<name>Mirror of http://repo1.maven.org/maven2/</name>
<url>http://ibiblio.lsu.edu/main/pub/packages/maven2</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
</settings>
I didn't have to put a repositories section in my pom.xml.
Richard Allen
Elliot Metsger wrote:
Hi Richard,
Thanks - I've followed that guide. I have mirrors defined per that
guide, but when I run a mvn compile and Maven attempts to download
deps, it seems to be doing it all from the central Ibiblio repo.
Do you mind sharing a pom.xml that uses the mirror? Specifically did
you have to add anything to your pom that references a mirror in your
settings.xml, or are the mirrors used automagically?
Elliot
Richard Allen wrote:
I've put mirrors in my settings.xml as described here:
http://maven.apache.org/guides/mini/guide-mirror-settings.html
It works well for me, especially the LSU mirror.
Richard Allen
Wayne Fay wrote:
Personally, I don't use settings.xml. So I didn't feel qualified to
answer your email, Elliot.
Instead I use <repositories> and <pluginRepositories> in my pom.xml
file.
It works --- I can see files being downloaded from the various mirrors
etc when I run mvn -U...
checking for updates from dotsrc
checking for updates from ibiblio
checking for updates from codehaus-plugins
checking for updates from central
Wayne
On 3/6/06, Elliot Metsger <[EMAIL PROTECTED]> wrote:
Hi Wayne,
Wayne Fay wrote:
Add some of the Maven mirrors to your pom.xml, so you can at least
download the artifacts etc from another site when ibiblio is giving
you problems.
If I have mirrors defined in my settings.xml, do I need to also put
them
in the pom.xml (see my earlier posting on getting the mirrors to
work).
I didn't see anywhere in the Maven 2 documentation about adding the
mirrors to pom.xml.
Thanks,
Elliot
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]