How to set retention policy in jfrog Artifactory - jfrog-cli

I'm looking for a way to set retention period in JFrog Arttifactory, which will remove SNAPSHOT versions older than 100 days.
If any teams need particular files need to be keep in Artifactory forever, need to exclude some path alone in that repo from retention policy and other directories should be removed as per the retention policy.

According to this article you should be able to build an AQL
that will help you find the artifacts you would like to delete and then use the code from the article to delete it.
Other than that, JFrog has a few built in plug-ins on the github page - you can see if one of them suits you.

Related

JFrog Cloud - custom artifactory.system.properties?

In JFrog Cloud, is there a way to add custom settings to the artifactory.system.properties file?
We'd like to enable numeric sorting in the artifact tree browser.
You can reach out to JFrog Support team who helps in changing the values according to your need.

Delete artifacts which are not downloaded for 6 months

In JFrog Artifactory, I need to delete the artifacts which are not downloaded for a period of 6 months. I have gone through the JFrog repository. It is mentioned to run via REST API, but I am not pretty sure how to use it.
How can we implement this? or if there is some other way?
I would recommend to refer to this user plugin, artifactCleanUp plugin can be used to delete artifacts which are not downloaded for certain days/months.
The easiest way would be to use the delete command of the JFrog CLI.
The command accepts a file spec.
Write an AQL query with Relative Time Operators, and pass it in the aql field of the file spec.

Jfrog CLI for Artifactory: download folder archive

I am using JFrog CLI (jfrog rt download) to download build reports from Artifactory that are published there by GitLab CI in unpacked state in order to allow unhindered html reports browsing.
However it takes extremely long (10-20 minutes) because of just how many small files there are.
I see that Artifactory has REST API to download whole repository folder content in one swoop as a single archive.
But I am not able to find any way to do the same using JFrog CLI.
Am I missing something or is there truly no way to download whole folder content as an archive using JFrog CLI?
P.S.: I am aware that there is a configuration option on Artifactory that supposedly allows to browse contents of archives, but there are reasons (organizational and technical) preventing me from using it
Using the CLI you can increase the "--threads" value. I have seen a massive improvement when downloading a directory with lots of small files when increasing the number of threads.

How to export and sync an Artifactory repository to the filesystem?

I am looking for a solution that would allow me to have a network share where people can access (read-only) the artifacts from an Artifactory repository.
Why? We use Artifactory to also keep track of big binaries like installation kits, ISO images and so on and it takes a lot of time to download all of them (sometimes as zips), unpack and run them. If these would be exported to a NFS/SMB share people would be able to only mount them in order to use them.
How can we achieve this? Please keep in mind that we also want to automate this, so the files would be updated by Artifactory when needed.
Artifactory supports WebDAV out of the box.
It seems that's not possible at this moment and there is a feature request for enabling it:
https://www.jfrog.com/jira/browse/RTFACT-8302
Feel free to vote and to comment on it, allowing jFrog to realise how important is this use case.
I guess they should be able to provide a script that does mirror/sync a repository to a NFS share but that would almost double the storage space needed.
Instead if they would use hardlinks or symlinks to create a browsable tree of the repository inside the storage directory, this would be solved and no sync will be needed.

fossil dvcs difference between update and checkout commands

After reading the builtin help, it seems to me that both commads can be used for modifying the workspace to match a certain revision. But I don't understand the differences between update and checkout. Please include some trivial workflows in your answer which show when update/checkout are appropriate.
First major difference is that if you have a remote url set, update will pull first latest artifacts from the remote repository.
Another difference is that if you have uncomitted changes, checkout will not run (unless you force it), whereas update will retain your changes and reapply them. With update you can therefore integrate changes from other users before committing.
So:
Update is what you need when you collaborate on a project, in order to prevent forks.
Checkout lets you deploy a particular version.

Resources