0

I am trying to build a Java project using Gradle. I have some dependencies (jars) that are in a location of the type: http://internal_domain.location.local:9000/artifacts/repo How do I specify this in the build.gradle file? Is it under repositories {}? In the gradle documentation I came across this but doing something similar does not work for me:

repositories {
   ivy {
    url "http://repo.mycompany.com/repo"
    resolve.dynamicMode = true
  }
}
user2399453
  • 2,930
  • 5
  • 33
  • 60
  • 2
    If it's a maven repository (judging by the question tags), you should switch `ivy {` with `maven {` – Ori Dar Aug 12 '15 at 19:01

1 Answers1

1

Assuming your local repo is a maven repo

repositories {
    maven {
        // Look for POMs and artifacts, such as JARs, here
        url "http://repo2.mycompany.com/maven2"
        // Look for artifacts here if not found at the above location
        artifactUrls "http://repo.mycompany.com/jars"
        artifactUrls "http://repo.mycompany.com/jars2"
    }
}

Local Archive Gradle

Pumphouse
  • 2,013
  • 17
  • 26