We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c8e8426 commit c02f0d3Copy full SHA for c02f0d3
1 file changed
scheduler/coreos.py
@@ -197,7 +197,7 @@ def attach(self, name):
197
[Service]
198
ExecStartPre=/usr/bin/docker pull {image}
199
ExecStartPre=/bin/sh -c "docker inspect {name} >/dev/null 2>&1 && docker rm -f {name} || true"
200
-ExecStart=/bin/sh -c "port=$(docker inspect -f '{{{{range $k, $v := .config.ExposedPorts }}}}{{{{$k}}}}{{{{end}}}}' {image} | cut -d/ -f1) ; docker run --name {name} -P -e PORT=$port {image} {command}"
+ExecStart=/bin/sh -c "port=$(docker inspect -f '{{{{range $k, $v := .ContainerConfig.ExposedPorts }}}}{{{{$k}}}}{{{{end}}}}' {image} | cut -d/ -f1) ; docker run --name {name} -P -e PORT=$port {image} {command}"
201
ExecStop=/usr/bin/docker rm -f {name}
202
TimeoutStartSec=20m
203
"""
0 commit comments