1
0
mirror of https://github.com/rancher/os.git synced 2025-09-01 23:04:41 +00:00
Files
os/images/02-console/docker-init

23 lines
457 B
Plaintext
Raw Normal View History

2016-05-06 10:12:09 -07:00
#!/bin/bash
set -e
2016-05-06 10:12:09 -07:00
if [ -e /var/lib/rancher/conf/docker ]; then
source /var/lib/rancher/conf/docker
fi
while [ ! -e /run/console-done ]; do
sleep 1
done
DOCKER_BIN=$(which docker) || DOCKER_BIN=/usr/bin/docker
for i in /opt/bin /usr/local/bin; do
if [ -x ${i}/docker ]; then
PATH=${i}:$PATH
DOCKER_BIN=${i}/docker
break
fi
done
2016-05-06 10:12:09 -07:00
exec /usr/bin/dockerlaunch $DOCKER_BIN "$@" $DOCKER_OPTS >>/var/log/docker.log 2>&1