Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the point of Artifactory or Nexus, and how might I use them?

While investigating CI tools, I've found that many installations of CI also integrate to artifact repositories like SonaType Nexus and JFrog Artifactory.

Those tools sound highly integrated to Maven. We do not use Maven, nor do we compile Java even. We compile C++ using Qt/qmake/make, and this build works really well for us. We are still investigating CI tools.

What is the point of using an Artifact repository?

Is archiving to Nexus or Artifactory (or Archiva) supposed to be a step in our make chain, or part of the CI chain, or could it be either?

How might I make our "make" builds or perl/bash/batch scripts interact with them?

like image 440
macetw Avatar asked May 10 '13 12:05

macetw


People also ask

Why is Nexus Artifactory used for?

Artifactory has a slight lead in the number of supported repo types, but Nexus provides you with OSGi interfaces, enabling you to make custom repository types if needed.

What is the purpose of Artifactory?

Artifactory optimizes storage by ensuring that any binary and its metadata are only stored once on the file system, under the name of its unique calculated checksum. Repositories hold only references to files, so the physical file is never duplicated, and its checksum can be used to verify the binary's integrity.

What is Nexus and Artifactory?

Artifactory stores the artifacts in a database, which means that if something goes wrong, all your artifacts are gone. Nexus uses a flat file for your precious artifacts so you don't have to worry about them all getting lost.

Why Nexus is used in DevOps?

With Nexus, developers can completely control access to, and deployment of, every artifact in an organization from a single location, making it easier to distribute software. It is most commonly used for hosting Apache Maven. Currently it supports Maven/Java, npm, NuGet, RubyGems, Docker, P2, OBR, APT and YUM and more.


1 Answers

An artifact repository has several purposes. The main purpose is to have an copy of maven central (or any other maven repo) to have faster download times and you can use maven even if the internet is down. Since your not using maven this is irrelevant for you.

The second purpose is to store files in it you want to use as dependency but you can not download freely from the internet. So you buy them or get them from your vendors and put them in your repo. This is also more applicable to maven user and there dependency mechanism.

The third important purpose is to have a central way were you can store your releases. So if you build a release v1.0 you can upload it to such a repository and with the clean way of naming in maven its kinda easy to know how to find v1.0 and to use it with all other tools. So you could write a script which downloads your release with wget and install it on a host.

Most of the time these repos have a way of a staging process. So you can store v1.0 in the repo in staging. Someone do the test and when its fine he promotes it to the release repo were everybody can find and use it.

Its simple to integrate them with Maven projects and they are lot of other build tools frameworks with has a easy possiblity to connect against it like ant ivy, groovy grape and so on. Because of the naming schema there is no limitation that you use bash or perl to download/upload files from it.

So if you have releases or files which should be shared between projects and do not have a good solution for it an artefact repository could be good starting point to see how this could work.

like image 83
mszalbach Avatar answered Dec 06 '22 17:12

mszalbach