From 25ff9bb770ea7f8932691ceddffc5aeab0612db4 Mon Sep 17 00:00:00 2001 From: Marcos Salgueiro Balsa Date: Sun, 1 Sep 2019 15:42:32 +0200 Subject: [PATCH] Fix: CrashLoopBackOff due to permission error The script file is copied w/o 'x' perms, so if run like this, the container will refuse to start due to a permission denied error: `/bin/sh: 1: /bin/fortuneloop.sh: Permission denied` Adding the 'x' permission or running it with `bash` fixes it. --- Chapter06/fortune/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Chapter06/fortune/Dockerfile b/Chapter06/fortune/Dockerfile index 350c230..ba1cd82 100644 --- a/Chapter06/fortune/Dockerfile +++ b/Chapter06/fortune/Dockerfile @@ -3,5 +3,5 @@ FROM ubuntu:latest RUN apt-get update ; apt-get -y install fortune ADD fortuneloop.sh /bin/fortuneloop.sh -ENTRYPOINT /bin/fortuneloop.sh +ENTRYPOINT bash /bin/fortuneloop.sh