Skip to content

Commit

Permalink
Allow workdir to be set properly when entrypoint is not invoked.
Browse files Browse the repository at this point in the history
  • Loading branch information
guzman-raphael committed Sep 22, 2021
1 parent b57ac02 commit cfa7592
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion utilities/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,4 @@ if ! [ $(id -u) = 0 ]; then
fi
fi
# Run command
pwd | grep -qvE "^\/home\/\.?anaconda$" || cd ~
"$@"
2 changes: 1 addition & 1 deletion utilities/shell_intercept.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ if ! [ $(id -u) = 0 ]; then
cd /tmp
/startup -user=$ORIG_USER -new_uid=$(id -u) -new_gid=$(id -g) -new_user=${NEW_USER} -new_home=$NEW_HOME
export HOME=/home/${NEW_USER}
cd $CURR_DIR 2>/dev/null || cd $HOME
echo $CURR_DIR | grep -qvE "^\/home\/\.?anaconda$" && cd $CURR_DIR || cd ~
fi
export PATH=$(readlink -f "$HOME")/.local/bin:$PATH

0 comments on commit cfa7592

Please sign in to comment.