This repository was archived by the owner on Sep 12, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -95,6 +95,37 @@ requests to the Docker Registry:
9595```
9696
9797
98+ ## High Availability and Scaling
99+
100+ It is possible to run multiple containers against the same storage
101+ back-end for performance and availability reasons.
102+
103+ Here is an example using a shared s3 storage back-end, Redis cache and
104+ MySQL search database (all should be common across containers for
105+ consistency)
106+
107+ ```
108+ docker run \
109+ -e SETTINGS_FLAVOR=s3 \
110+ -e AWS_BUCKET=mybucket \
111+ -e AWS_KEY=myawskey \
112+ -e AWS_SECRET=myawssecret \
113+ -e CACHE_REDIS_HOST=redis.host \
114+ -e CACHE_REDIS_PORT=6379 \
115+ -e CACHE_REDIS_DB=1 \
116+ -e CACHE_LRU_REDIS_HOST=redis.host \
117+ -e CACHE_LRU_REDIS_PORT=6379 \
118+ -e CACHE_LRU_REDIS_DB=0 \
119+ -e AWS_REGION=us-east-1 \
120+ -e SEARCH_BACKEND=sqlalchemy \
121+ -e SQLALCHEMY_INDEX_DATABASE=mysql://user:pass@mysql.host/db_name
122+ -p 5000:5000 \
123+ registry
124+ ```
125+
126+ _ note: Depending on your version of Docker you may need to add the
127+ appropriate python mysql drivers to the container_
128+
98129## Alternative uses
99130
100131If you don't want to run the registry inside a docker container, you may do so by running it directly, as follow:
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ RUN apt-get update \
1616 python-pip \
1717# Install deps for backports.lzma (python2 requires it)
1818 python-dev \
19+ python-mysqldb \
1920 python-rsa \
2021 libssl-dev \
2122 liblzma-dev \
You can’t perform that action at this time.
0 commit comments