Skip to main content

A simple docker registry cleaner

Project description

A simple cleaner for private docker-registries.

Installation

$ pip install docker-registry-purger

Usage

Clean registry using standard options (i.e keep at less 7 versions, drop only packages older than 180 days, developement packages older than 30 days and rc packages older than 90 days).

$ docker-registry-purger 'https://[username]:[password]@[your_repository]'
$ # OR if you have your credentials in ``.netrc``
$ docker-registry-purger 'https://[your_repository]'

This script only drops references to blobs, the blobs themself are not deleted, to remove them you have to follow the procedure describe on https://docs.docker.com/registry/garbage-collection/#run-garbage-collection.

You can test this script with the dry-run option:

$ docker-registry-purger --dry-run 'https://[username]:[password]@[your_repository]'

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
docker_registry_purger-0.1.1-py3-none-any.whl (4.1 kB) Copy SHA256 hash SHA256 Wheel py3
docker-registry-purger-0.1.1.tar.gz (4.5 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page