Skip to content

Commit 1b77523

Browse files
authored
Merge pull request #1523 from mathbunnyru/asalikhov/fix_when_symlink_fails
Fail if creating symlink fails
2 parents 425794a + f8c281a commit 1b77523

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

base-notebook/start.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,12 +95,13 @@ if [ "$(id -u)" == 0 ] ; then
9595
if cp -a /home/jovyan/. "/home/${NB_USER}/"; then
9696
echo "Success!"
9797
else
98-
echo "Failed!"
98+
echo "Failed to copy data from /home/jovyan to /home/${NB_USER}!"
9999
echo "Attempting to symlink /home/jovyan to /home/${NB_USER}..."
100100
if ln -s /home/jovyan "/home/${NB_USER}"; then
101-
echo "Success!"
101+
echo "Success creating symlink!"
102102
else
103-
echo "Failed!"
103+
echo "Failed to create symlink!"
104+
exit 1
104105
fi
105106
fi
106107
fi

0 commit comments

Comments
 (0)