We have a feature request to support the removal of orphaned docker images (ones that don't have tags or aren't used as layers by other images) in Katello so we'd like a command and API call to remove these images. http://projects.theforeman.org/issues/7811
Pulp doesn't have API endpoints that implement workflows for specific content types. We might add a command to our CLI to do something like this, but I don't think it makes sense to have it as part of our content-agnostic REST API. I recommend that katello proceeds with this in the web UI. Looking at any specific repo, it should be straight-forward to identify layers that are not tagged nor referenced by another layer in the repo, and offer to remove them from the repo with the normal unit remove operation. This whole workflow is subject to change once the v2 registry API and "manifest" concepts are fully integrated into docker.
Moved to https://pulp.plan.io/issues/276