From 4ffcb637687c782b68f309b2d7bc969135d9a71a Mon Sep 17 00:00:00 2001 From: djarpin Date: Tue, 19 Dec 2017 13:11:54 -0800 Subject: [PATCH] Fixed: build_and_push.sh to include docker restart command --- .../scikit_bring_your_own/container/build_and_push.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/advanced_functionality/scikit_bring_your_own/container/build_and_push.sh b/advanced_functionality/scikit_bring_your_own/container/build_and_push.sh index 0a32b04564..a543910612 100755 --- a/advanced_functionality/scikit_bring_your_own/container/build_and_push.sh +++ b/advanced_functionality/scikit_bring_your_own/container/build_and_push.sh @@ -43,6 +43,13 @@ $(aws ecr get-login --region ${region} --no-include-email) # Build the docker image locally with the image name and then push it to ECR # with the full name. + +# On a SageMaker Notebook Instance, the docker daemon may need to be restarted in order +# to detect your network configuration correctly. (This is a known issue.) +if [ -d "/home/ec2-user/SageMaker" ]; then + sudo service docker restart +fi + docker build -t ${image} . docker tag ${image} ${fullname}