Skip to content

Commit 54ea656

Browse files
authored
Fix error: failed to create directory via template '/tmp/nix-shell.XXXXXX/' (input-output-hk#157)
mktemp: failed to create directory via template '/tmp/nix-shell.xsPtzA/nix-shell.XXXXXX': No such file or directory
1 parent 6ee20d6 commit 54ea656

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Dockerfile

+8
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,14 @@ RUN DEBIAN_FRONTEND=noninteractive \
2020
&& ./fetch-docker.sh input-output-hk/devx $PLATFORM.$COMPILER_NIX_NAME$TARGET_PLATFORM$VARIANT$IOG-env | zstd -d | nix-store --import | tee store-paths.txt
2121

2222
RUN cat <<EOF >> $HOME/.bashrc
23+
# This fix: mktemp: failed to create directory via template '/tmp/nix-shell.XXXXXX/' ...
24+
if [ -n "\$VSCODE_GIT_IPC_HANDLE" ]; then
25+
mkdir -p "\$(dirname "\$VSCODE_GIT_IPC_HANDLE")"
26+
fi
27+
if [ -n "\$VSCODE_IPC_HOOK_CLI" ]; then
28+
mkdir -p "\$(dirname "\$VSCODE_IPC_HOOK_CLI")"
29+
fi
30+
# This line is the one that actually brings DevX devshell ...
2331
source $(grep -m 1 -e '-env.sh$' store-paths.txt)
2432
EOF
2533

0 commit comments

Comments
 (0)