Created
April 25, 2017 22:02
-
-
Save t3h2mas/314838a49f876c64e4697d640853da9d to your computer and use it in GitHub Desktop.
Deploy registry to Docker Swarm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
docker service create --name registry \ | |
-e "REGISTRY_STORAGE=s3" \ | |
-e "REGISTRY_STORAGE_S3_REGION=[S3 REGION]" \ | |
-e "REGISTRY_STORAGE_S3_ACCESSKEY=[ACCESS KEY]" \ | |
-e "REGISTRY_STORAGE_S3_SECRETKEY=[SECRET KEY]" \ | |
-e "REGISTRY_STORAGE_S3_BUCKET=[BUCKET NAME]" \ | |
-e "REGISTRY_STORAGE_S3_ENCRYPT=true" \ | |
--publish 5000:5000 \ | |
registry:2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
TODO: Add restart policy if the default isn't sufficient