Skip to content

Commit 46c54fe

Browse files
committed
devcontainer(just): add system-wide PATH in /etc/environment for sudo sessions
Signed-off-by: Aaron Wislang <aaron.wislang@microsoft.com>
1 parent 98fec14 commit 46c54fe

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

.devcontainer/just/Dockerfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ ENV CARGO_HOME=/home/vscode/.cargo
2525
ENV RUSTUP_HOME=/home/vscode/.rustup
2626
ENV PATH=/home/vscode/.npm-global/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/opt/llm-env/bin:/usr/local/go/bin:${PATH}
2727

28+
# Configure system-wide PATH via /etc/environment for sudo sessions
29+
RUN echo 'PATH="/home/vscode/.npm-global/bin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/opt/llm-env/bin:/home/vscode/.cargo/bin:/usr/local/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"' >> /etc/environment
30+
2831
RUN mkdir -p ${CARGO_HOME} /home/vscode/.rustup /home/vscode/.npm-global \
2932
&& chown -R vscode:vscode ${CARGO_HOME} /home/vscode/.rustup /home/vscode/.npm-global
3033

0 commit comments

Comments
 (0)