# docker-cleanup

- Usage

`docker-cleanup` is a command to perform precommit's Docker cleanup functionality outside of patch and build testing.

# Usage

Executing `docker-cleanup` will peform the same Docker image as the `--robot` option.

    $ docker-cleanup

    ...
            Removing old images
    ...
    Untagged: hadoop/createrelease:3.0.0-alpha3-SNAPSHOT_10600
    Deleted: sha256:1a96c79a0a9ab538c6c7765dc908eca3e689270b778d6ae2add558e89792a7d8
    ...
                           Docker Container Maintenance
    ...

`docker-cleanup` also supports the `--sentinel` mode to kill and remove stale running containers:

    $ docker-cleanup --sentinel

    ...
                                Removing old images
    ...
    Untagged: hadoop/createrelease:3.0.0-alpha3-SNAPSHOT_10600
    Deleted: sha256:1a96c79a0a9ab538c6c7765dc908eca3e689270b778d6ae2add558e89792a7d8
    ...

                           Docker Container Maintenance
    ...
    Attempting to remove docker container /big_kowalevski [5ffd22a56ebcfe38d72b9078e0e7133ab6dc054115a4804e504c910bdbdeea45]
    ...