From: Michal Sojka Date: Mon, 18 Nov 2019 08:20:28 +0000 (+0100) Subject: server: User temporary RUN_DIR in $HOME does not exist X-Git-Tag: 20201217~15 X-Git-Url: http://rtime.felk.cvut.cz/gitweb/novaboot.git/commitdiff_plain/4e4e77baf6ab6a31d138cb371c729196d944d8b5 server: User temporary RUN_DIR in $HOME does not exist This is the case under pbuilder. --- diff --git a/server/novaboot-shell b/server/novaboot-shell index 52c70e4..a9300b7 100755 --- a/server/novaboot-shell +++ b/server/novaboot-shell @@ -166,7 +166,12 @@ main() { esac } -RUN_DIR="$HOME" +if [ -d "$HOME" ]; then + RUN_DIR="$HOME" +else + RUN_DIR="/tmp/novaboot-shell@$USER" + mkdir -p "$RUN_DIR" +fi if [ -z "$NOVABOOT_ID" ]; then main "$@"