Created
April 23, 2018 11:23
-
-
Save lavagetto/796c3b69177db22b957895c641e73ff9 to your computer and use it in GitHub Desktop.
mcrouter ssl test
This file contains hidden or 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
# Dockerfile | |
from docker-registry.wikimedia.org/wikimedia-stretch:latest | |
RUN apt-get update && apt-get -y install mcrouter && rm -rf /var/lib/apt/lists/* \ | |
&& mkdir -p /etc/mcrouter | |
VOLUME ["/etc/mcrouter"] | |
CMD ["/usr/bin/mcrouter", "--ssl-port", "11210", "--pem-cert-path=/etc/mcrouter/cert.pem", "--pem-key-path=/etc/mcrouter/key.pem", "--pem-ca-path=/etc/mcrouter/ca.pem", "-f", "/etc/mcrouter/config.json", "--port", "11211"] | |
# Instance one - memcacheds are exposed on the local IP at ports 20200 and 20201 | |
## config.json | |
{ | |
"pools": { | |
"test": { | |
"servers": [ | |
"$IP:20200:ascii:plain", | |
"$IP:20201:ascii:plain" | |
] | |
} | |
}, | |
"route": "PoolRoute|test" | |
} | |
# Instance two - the ssl port for instance 1 is exposed on port 11210 | |
## config.json | |
{ | |
"pools": { | |
"test": { | |
"servers": [ | |
"$IP:11210:ascii:ssl", | |
] | |
} | |
}, | |
"route": "PoolRoute|test" | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment