Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MESOS: Automated cherry pick of #16769 - docker-compose 1.5.0 #17715

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
39 changes: 15 additions & 24 deletions cluster/mesos/docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ mesosslave:
- bash
- -xc
- >
NAME=$(cut -f2 -d/ <<<${MESOSMASTER1_NAME}) &&
N=${NAME##*_} &&
DOCKER_NETWORK_OFFSET=0.0.${N}.0
NAME=$$(cut -f2 -d/ <<<$${MESOSMASTER1_NAME}) &&
N=$${NAME##*_} &&
DOCKER_NETWORK_OFFSET=0.0.$${N}.0
exec wrapdocker mesos-slave
--work_dir="/var/tmp/mesos/${N}"
--attributes="rack:${N};gen:201${N}"
--hostname=$(getent hosts mesosslave | cut -d' ' -f1 | sort -u | tail -1)
command: ~
--work_dir="/var/tmp/mesos/$${N}"
--attributes="rack:$${N};gen:201$${N}"
--hostname=$$(getent hosts mesosslave | cut -d' ' -f1 | sort -u | tail -1)
command: []
environment:
- MESOS_MASTER=mesosmaster1:5050
- MESOS_PORT=5051
Expand All @@ -64,13 +64,13 @@ apiserver:
- /bin/bash
- "-ceu"
- >
echo "Hostname: $(hostname -f) ($(hostname -f | xargs resolveip))" &&
echo "Hostname: $$(hostname -f) ($$(hostname -f | xargs resolveip))" &&
(grep "mesos-master\s*=" /opt/mesos-cloud.conf || echo " mesos-master = mesosmaster1:5050" >> /opt/mesos-cloud.conf) &&
await-health-check "-t=${MESOS_DOCKER_ETCD_TIMEOUT}" http://etcd:4001/health &&
await-health-check "-t=${MESOS_DOCKER_MESOS_TIMEOUT}" http://mesosmaster1:5050/health &&
await-file "-t=${KUBE_KEYGEN_TIMEOUT}" /var/run/kubernetes/auth/apiserver.crt &&
km apiserver
--address=$(resolveip apiserver)
--address=$$(resolveip apiserver)
--external-hostname=apiserver
--etcd-servers=http://etcd:4001
--port=8888
Expand All @@ -87,10 +87,6 @@ apiserver:
--tls-private-key-file=/var/run/kubernetes/auth/apiserver.key
--v=4
ports: [ "8888:8888", "6443:6443" ]
environment:
- MESOS_DOCKER_ETCD_TIMEOUT
- MESOS_DOCKER_MESOS_TIMEOUT
- KUBE_KEYGEN_TIMEOUT
volumes:
- ${MESOS_DOCKER_WORK_DIR}/auth:/var/run/kubernetes/auth:ro
links:
Expand All @@ -103,20 +99,17 @@ controller:
- /bin/bash
- "-ceu"
- >
echo "Hostname: $(hostname -f) ($(hostname -f | xargs resolveip))" &&
echo "Hostname: $$(hostname -f) ($$(hostname -f | xargs resolveip))" &&
(grep "mesos-master\s*=" /opt/mesos-cloud.conf || echo " mesos-master = mesosmaster1:5050" >> /opt/mesos-cloud.conf) &&
await-health-check "-t=${MESOS_DOCKER_MESOS_TIMEOUT}" http://mesosmaster1:5050/health &&
await-health-check "-t=${MESOS_DOCKER_API_TIMEOUT}" http://apiserver:8888/healthz &&
km controller-manager
--address=$(resolveip controller)
--address=$$(resolveip controller)
--master=http://apiserver:8888
--cloud-config=/opt/mesos-cloud.conf
--service-account-private-key-file=/var/run/kubernetes/auth/service-accounts.key
--root-ca-file=/var/run/kubernetes/auth/root-ca.crt
--v=4
environment:
- MESOS_DOCKER_MESOS_TIMEOUT
- MESOS_DOCKER_API_TIMEOUT
volumes:
- ${MESOS_DOCKER_WORK_DIR}/auth:/var/run/kubernetes/auth:ro
links:
Expand All @@ -129,13 +122,13 @@ scheduler:
- /bin/bash
- "-ceu"
- >
echo "Hostname: $(hostname -f) ($(hostname -f | xargs resolveip))" &&
echo "Hostname: $$(hostname -f) ($$(hostname -f | xargs resolveip))" &&
(grep "mesos-master\s*=" /opt/mesos-cloud.conf || echo " mesos-master = mesosmaster1:5050" >> /opt/mesos-cloud.conf) &&
await-health-check "-t=${MESOS_DOCKER_ETCD_TIMEOUT}" http://etcd:4001/health &&
await-health-check "-t=${MESOS_DOCKER_MESOS_TIMEOUT}" http://mesosmaster1:5050/health &&
await-health-check "-t=${MESOS_DOCKER_API_TIMEOUT}" http://apiserver:8888/healthz &&
km scheduler
--address=$(resolveip scheduler)
--address=$$(resolveip scheduler)
--hostname-override=scheduler
--etcd-servers=http://etcd:4001
--mesos-user=root
Expand All @@ -144,10 +137,8 @@ scheduler:
--cluster-dns=10.10.10.10
--cluster-domain=cluster.local
--v=4
environment:
- MESOS_DOCKER_ETCD_TIMEOUT
- MESOS_DOCKER_MESOS_TIMEOUT
- MESOS_DOCKER_API_TIMEOUT
--executor-logv=4
--profiling=true
links:
- etcd
- mesosmaster1
Expand Down
2 changes: 1 addition & 1 deletion cluster/mesos/docker/test/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ RUN apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 581
&& \
apt-get clean

RUN pip install -U docker-compose
RUN pip install -U docker-compose==1.5.0

RUN go get github.com/tools/godep

Expand Down