Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Commit

Permalink
add timeout to restart docker (#2457)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cecile Robert-Michon authored and jackfrancis committed Mar 19, 2018
1 parent cb5f620 commit e22b3fc
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions parts/k8s/kubernetesmastercustomscript.sh
Original file line number Diff line number Diff line change
Expand Up @@ -487,12 +487,11 @@ function ensureDocker() {
systemctlEnableAndCheck docker
# only start if a reboot is not required
if ! $REBOOTREQUIRED; then
systemctl restart docker
dockerStarted=1
for i in {1..900}; do
if ! /usr/bin/docker info; then
echo "status $?"
/bin/systemctl restart docker
timeout 60s /bin/systemctl restart docker
else
echo "docker started, took $i seconds"
dockerStarted=0
Expand Down

0 comments on commit e22b3fc

Please sign in to comment.