Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

It's possible to put binary files on nexus repository?

At my work all development uses Java technology, and we use Nexus to manage our Maven repositories. But for a new project, the build requires dll and exe artifacts. Is it possible to put those windows binary files into a Nexus repository? Is there some plugin to make this simpler? Is what I'm trying to do crazy?

like image 896
PRF Avatar asked Sep 07 '10 20:09

PRF


People also ask

Is Nexus a binary repository?

"We have had good experience with Nexus as a our binary repository. Because nexus caches all JAR packages form 3rd party repositories, our build are stable and are unaffected if a 3rd party repository is down."

Which all type of repositories content does Nexus support?

Nexus Repository Manager provides for three different kinds of repositories: Proxy repositories, Hosted repositories and Virtual repositories.

Can Nexus repository can store third party jars?

Nexus has very low resource requirements, and it is something you can run on an existing workgroup collaboration machine or locally. When you upload a 3rd-party JAR to your own Nexus instance, it will immediately be integrated with Nexus search capabilities and be available to your organization's builds.


1 Answers

I use Nexus to store all the binary dependencies that I download from the internet.

You can upload the files using the Nexus GUI or use the Maven command line as follows:

mvn deploy:deploy-file \
    -Durl=$REPO_URL \
    -DrepositoryId=$REPO_ID \
    -DgroupId=org.apache.maven \
    -DartifactId=maven \
    -Dversion=2.2.1  \
    -Dpackaging=zip \
    -Dfile=maven.zip

This will generate the POM for your zip package automatically.

To retrieve dependencies, you can just navigate to the Nexus URL, or use a generic dependency manager tool like ivy:

java -jar ivy.jar -dependency org.apache.maven maven 2.2.1 -retrieve [artifact].[ext]
like image 146
Mark O'Connor Avatar answered Sep 22 '22 16:09

Mark O'Connor