We can set/modify the following system properties in
For instance, to set the maximum age of a layer to 24 hours and to schedule the job to run once per day, add the sample configuration below to the
Note: Changing the frequency may affect the performance of Artifactory based on the job's frequency, the number of local repositories, and the volume of files we need to delete.
Important: When configuring the cleanup job, make sure to take into account situations where a slow client uploads a large Docker image. In these cases, the delta between the deployment of the first layer to the upload of the manifest file must not be greater than the “artifactory.docker.cleanup.maxAgeMillis” property, otherwise, the layer might be removed and the push will fail consequently.
$JFROG_HOME/artifactory/var/etc/artifactory/artifactory.system.propertiesfile in order to configure the cleanup job the is responsible to clean up the “_uploads” directory:
- artifactory.docker.cleanup.maxAgeMillis – this property determines the age of files to be deleted by the job.
- artifactory.docker.cleanup.uploadsTmpFolderJobSecs – this property determines how frequently this job should run.
For instance, to set the maximum age of a layer to 24 hours and to schedule the job to run once per day, add the sample configuration below to the
$JFROG_HOME/artifactory/var/etc/artifactory/artifactory.system.propertiesfile and restart Artifactory for the chances to take effect:
artifactory.docker.cleanup.maxAgeMillis=86400000 artifactory.docker.cleanup.uploadsTmpFolderJobSecs=86400
Note: Changing the frequency may affect the performance of Artifactory based on the job's frequency, the number of local repositories, and the volume of files we need to delete.
Important: When configuring the cleanup job, make sure to take into account situations where a slow client uploads a large Docker image. In these cases, the delta between the deployment of the first layer to the upload of the manifest file must not be greater than the “artifactory.docker.cleanup.maxAgeMillis” property, otherwise, the layer might be removed and the push will fail consequently.