Skip to content
Prev Previous commit
Next Next commit
fix user permission
  • Loading branch information
samruddhikhandale committed Mar 10, 2023
commit 044f92f9275328cc9ba89e9852525c696b143825
10 changes: 6 additions & 4 deletions src/miniconda/.devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,18 @@ RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
&& usermod -aG conda ${USERNAME} \
&& apt-get clean -y && rm -rf /var/lib/apt/lists/* /tmp/library-scripts/add-notice.sh

# Temporary: Upgrade 'cryptography' due to https://github.com/advisories/GHSA-39hc-v87j-747x
# 'cryptography' is installed by the base image (continuumio/miniconda3) which does not have the patch.
RUN conda update -y cryptography

# Copy environment.yml (if found) to a temp locaition so we update the environment. Also
# copy "noop.txt" so the COPY instruction does not fail if no environment.yml exists.
COPY environment.yml* noop.txt /tmp/conda-tmp/
RUN if [ -f "/tmp/conda-tmp/environment.yml" ]; then umask 0002 && /opt/conda/bin/conda env update -n base -f /tmp/conda-tmp/environment.yml; fi \
&& rm -rf /tmp/conda-tmp

USER vscode

# Temporary: Upgrade 'cryptography' due to https://github.com/advisories/GHSA-39hc-v87j-747x
# 'cryptography' is installed by the base image (continuumio/miniconda3) which does not have the patch.
RUN python3 -m conda update -y cryptography

# [Optional] Uncomment this section to install additional OS packages.
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
# && apt-get -y install --no-install-recommends <your-package-list-here>