In our project, we are migrating from ant scripts to gradle build.
We are going to use artifactory as a repo manager in our company to store artifacts.
I have seen some repository stuff in artifactory, consisting of libs-snapshot-local
as a remote repository and libs-snapshot
as virtual repository. Same with releases repo libs-release-local
and libs-release
.
Can any one of you explain what is the difference between them? Can I deploy the artifacts to both of them?
By definition, snapshots are mutable, releases are immutable. This is why Nexus makes you store them separately because usually you don't care if you lose snapshots, but you will care if you lose releases. It makes snapshot cleanup much easier to deal with that way.
Maven Snapshot Version BehaviorArtifactory supports centralized control of how snapshots are deployed into a repository, regardless of end user-specific settings. This can be used to guarantee a standardized format for deployed snapshots within your organization.
Local repositories are physical, locally-managed repositories into which you can deploy artifacts. Using local repositories, Artifactory gives you a central location to store your internal binaries. Through repository replication, you can even share binaries with teams that are located in remote locations.
Virtual repository, as explained in the documentation, unify other remote, local and virtual repositories to provide a single URL for resolution.
libs-snapshot-local
is not a remote repository, but a local repository. As explained in the documentation, local repositories are physical repositories in Artifactory which serve as targets for your deployments.
You don't need to deploy artifacts to both of them. Deploying to local makes the deployed artifacts available for retrieval from the virtual.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With