2

I want to create a local maven2 repository so we can download dependencies faster.

we use sbt

what is the simplest way to take all or some depedencies from http://oss.sonatype.org/content/repositories/releases and put it in our server

I was thinking of a script to download some jars and put it in a sftp server and use sftp resolver with sbt https://github.com/harrah/xsbt/wiki/Resolvers

Guillaume Massé
  • 8,004
  • 8
  • 44
  • 57

1 Answers1

3

A pretty simple way would be to install a repository manager. A popular one is Sonatype Nexus (the application that serves http://oss.sonatype.org). The repository manager is installed on your server, and set up to proxy online Maven repositories. Then you download your dependencies from the repository manager as though it was the actual server. The first time you download a dependency, it'll be as slow as before (the proxy will download it from the internet), but after that, it'll serve its cached copy. There are some details on this question.

Community
  • 1
  • 1
Daniel
  • 10,115
  • 3
  • 44
  • 62