alert-garage-57347
12/11/2022, 4:29 AMTARBALL_DEST=$(mktemp -t pulumi.tar.gz.XXXXXXXXXX)
works but EXTRACT_DIR=$(mktemp -d pulumi.XXXXXXXXXX)
fails with permission denied. Does anyone know how to fix this?FROM rust:1.65.0
WORKDIR /app
ARG USERNAME=vscode
ARG USER_UID=1000
ARG USER_GID=$USER_UID
# Create the user
RUN groupadd --gid $USER_GID $USERNAME \
&& useradd --uid $USER_UID --gid $USER_GID -m $USERNAME
RUN mkdir /app/target
RUN chown $USERNAME:$USERNAME /app/target
USER $USERNAME
ARG HOME_TMPDIR="/home/$USERNAME/.tmp"
RUN mkdir "$HOME_TMPDIR"
RUN chmod -R 777 "$HOME_TMPDIR"
RUN curl -fsSL <https://get.pulumi.com> | TMPDIR="$HOME_TMPDIR" sh
RUN rustup component add rustfmt clippy
RUN cargo install sqlx-cli
CMD ["echo", "Container is running"]
[2022-12-11T04:32:28.502Z] + Extracting to /home/vscode/.pulumi/bin
[2022-12-11T04:32:28.503Z] mktemp: failed to create directory via template 'pulumi.XXXXXXXXXX': Permission denied
[2022-12-11T04:32:28.503Z]
We're sorry, but it looks like something might have gone wrong during installation.
If you need help, please join us on <https://slack.pulumi.com/>
[2022-12-11T04:32:28.712Z] The command '/bin/sh -c curl -fsSL <https://get.pulumi.com> | TMPDIR="$HOME_TMPDIR" sh' returned a non-zero code: 1
-t
so it was trying to create under /
directory. I managed to work around this by changing the Dockerfile RUN line to RUN cd /tmp && (curl -fsSL <https://get.pulumi.com> | sh) && cd -
but I wonder why -t
was not provided in the official install script?echoing-dinner-19531
12/12/2022, 12:07 AM