devopshq / artifactory-cleanup

Extended cleanup tool for JFrog Artifactory
MIT License
121 stars 65 forks source link

Save removed artifacts list to json file #136

Closed roytev closed 2 months ago

roytev commented 7 months ago

Adds the ability to save the full output of artifacts_to_remove per policy to json file. i want to save the files for report generation and for auditing.

allburov commented 7 months ago

I see, the current --output does it at the end with the summary.

We should rename the current one to something like --output-removed with --output-removed-format may be (which is only JSON for now)

allburov commented 7 months ago

Also in the current approach if network stop working in the middle - you'll lose all previously removed artifacts for the policy, no file will be created. We handle it by either add different format where we could add it line by line right when we removed it (like CSV) or adding track really removed artifacts and write them down at the end

Or just ignore that case, but we should document it :)

roytev commented 7 months ago

Hi @allburov Thanks for your review!! you are right i went with more simpler approach can you see again ?

roytev commented 7 months ago

Hi @allburov Thanks again! ive fixed according to your review :)

allburov commented 7 months ago

Hi! Could you merge the current master branch in here please? I see we have conficts now

allburov commented 2 months ago

Merged in https://github.com/devopshq/artifactory-cleanup/pull/145