Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
description "Docker container for registry"
start on filesystem and started docker
stop on runlevel [06]
respawn
script
exec docker run \
-e REGISTRY_LOG_LEVEL=warn \
-e REGISTRY_STORAGE=s3 \
-e REGISTRY_STORAGE_S3_REGION=us-west-1 \
-e REGISTRY_STORAGE_S3_BUCKET=my-bucket \
-e REGISTRY_STORAGE_S3_ROOTDIRECTORY=my-folder/my-subfolder/my-sub-subfolder \
--log-driver=syslog \
-p 5000:5000 \
--rm \
--name=registry \
registry:2 None
end script
pre-stop script
/usr/bin/docker stop \
registry
/usr/bin/docker rm registry
end script
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment