Skip to content

Instantly share code, notes, and snippets.

@truatpasteurdotfr
Created December 14, 2020 16:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save truatpasteurdotfr/1819249ee1eb4d156a86d01c9f9e35c7 to your computer and use it in GitHub Desktop.
Save truatpasteurdotfr/1819249ee1eb4d156a86d01c9f9e35c7 to your computer and use it in GitHub Desktop.
quick and dirty miniconda on CentOS7 for R 4.0 and python 3.6
Bootstrap: docker
From: centos:7
%post
yum -y update && \
yum -y install bzip2 && \
yum -y clean all
# install miniconda
curl -qsSLkO https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh \
&& bash Miniconda3-latest-Linux-x86_64.sh -b -p /opt/miniconda3 \
&& rm Miniconda3-latest-Linux-x86_64.sh
/opt/miniconda3/bin/conda update conda && /opt/miniconda3/bin/conda update --all
PATH=/opt/miniconda3/bin:$PATH
export PATH
conda install r=4.0 python=3.6 -c r -c conda-forge -c anaconda
/opt/miniconda3/bin/conda list > /conda.txt
touch /`date -u -Iseconds`
%environment
PATH=/opt/miniconda3/bin:$PATH
export PATH
# do not use ~/.local python
PYTHONNOUSERSITE=1
export PYTHONNOUSERSITE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment