From 0630d8051b46d1eda3fdc06ab03650d0a7da76c7 Mon Sep 17 00:00:00 2001 From: Pagan Gazzard Date: Sat, 20 Sep 2014 00:53:06 +0100 Subject: [PATCH] Only try to copy the enter.sh if there is a /data directory. --- entry.sh | 6 ++++++ package.json | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/entry.sh b/entry.sh index 214132e2..fa7588dd 100755 --- a/entry.sh +++ b/entry.sh @@ -9,4 +9,10 @@ set -e cd /app +set DATA_DIRECTORY = /data +if [ -d "$DATA_DIRECTORY" ]; then + cp bin/enter.sh $DATA_DIRECTORY/enter.sh + chmod +x $DATA_DIRECTORY/enter.sh +fi + exec node src/supervisor.js diff --git a/package.json b/package.json index fb8a018b..789c97dd 100644 --- a/package.json +++ b/package.json @@ -4,7 +4,6 @@ "scripts": { "preinstall": "bash deps.sh", "postinstall": "bash postinstall.sh", - "prestart": "cp bin/enter.sh /data/enter.sh && chmod +x /data/enter.sh", "start": "./entry.sh" }, "dependencies": {