<VirtualHost *:80>
ServerName docker.initedit.com
RewriteEngine on
RewriteCond %{SERVER_NAME} =docker.initedit.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,QSA,R=permanent]
</VirtualHost>
<VirtualHost *:443>
<Location />
AuthName authorization
AuthType Basic
require valid-user
AuthUserFile '/etc/httpd/admin-htpasswd'
</Location>
ServerName docker.initedit.com
AllowEncodedSlashes on
RewriteEngine on
SSLEngine On
SSLProxyEngine On
ProxyPreserveHost On
RequestHeader set X-Forwarded-Proto "https"
ProxyPass / http://192.168.0.183:30005/
ProxyPassReverse / http://192.168.0.183:30005/
SSLCertificateFile /etc/letsencrypt/live/docker.initedit.com/cert.pem
SSLCertificateKeyFile /etc/letsencrypt/live/docker.initedit.com/privkey.pem
SSLCertificateChainFile /etc/letsencrypt/live/docker.initedit.com/fullchain.pem
Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
Note: Add htpasswd for basic authentication
docker tag docker.io/busybox docker.initedit.com/busybox1 docker push docker.initedit.com/busybox1
3. You can delete from UI and also using docker_reg_tool. After deleting you need to run below command inside registry container to remove it completely
6. Delete images form registry server we will use docker_reg_tool https://github.com/byrnedo/docker-reg-tool/blob/master/docker_reg_tool
Note: – Delete blobdescriptor: inmemory part from /etc/docker/registry/config.yml which is already have done in this example – REGISTRY_STORAGE_DELETE_ENABLED = “true” should be present in env
./docker_reg_tool http://192.168.0.183:30500 delete debianlocal latest
#This can be cronjob inside the container
docker exec -it name_of_registory_container bin/registry garbage-collect /etc/docker/registry/config.yml