Skip to content
Snippets Groups Projects
Commit 4688def9 authored by Amir MOHAMMADI's avatar Amir MOHAMMADI
Browse files

handle package cache better in Linux

parent c0a05db1
No related branches found
No related tags found
1 merge request!63Conda package based CI
...@@ -2,6 +2,15 @@ ...@@ -2,6 +2,15 @@
# Wed 21 Sep 2016 13:08:05 CEST # Wed 21 Sep 2016 13:08:05 CEST
source $(dirname ${0})/functions.sh source $(dirname ${0})/functions.sh
# Move the cache to conda folder
if [ "${OSNAME}" == "linux" ]; then
mkdir -p ${CONDA_FOLDER}/pkgs
touch ${CONDA_FOLDER}/pkgs/urls
touch ${CONDA_FOLDER}/pkgs/urls.txt
fi
merge_conda_cache ${CONDA_FOLDER}/pkgs ${CONDA_ENVS_PATH}/.pkgs
run_cmd ${CONDA_FOLDER}/bin/conda install --override-channels -c https://repo.continuum.io/pkgs/main -c https://repo.continuum.io/pkgs/free -c https://repo.continuum.io/pkgs/r -c https://repo.continuum.io/pkgs/pro -n root --yes --quiet conda=4.3.27 conda-build=3.0.22 run_cmd ${CONDA_FOLDER}/bin/conda install --override-channels -c https://repo.continuum.io/pkgs/main -c https://repo.continuum.io/pkgs/free -c https://repo.continuum.io/pkgs/r -c https://repo.continuum.io/pkgs/pro -n root --yes --quiet conda=4.3.27 conda-build=3.0.22
run_cmd ${CONDA_FOLDER}/bin/conda config --set always_yes yes --set changeps1 no run_cmd ${CONDA_FOLDER}/bin/conda config --set always_yes yes --set changeps1 no
run_cmd ${CONDA_FOLDER}/bin/conda config --set show_channel_urls true run_cmd ${CONDA_FOLDER}/bin/conda config --set show_channel_urls true
...@@ -29,11 +38,10 @@ else ...@@ -29,11 +38,10 @@ else
run_cmd ${CONDA_FOLDER}/bin/conda build --override-channels -c ${CONDA_CHANNEL} -c https://repo.continuum.io/pkgs/main -c https://repo.continuum.io/pkgs/free -c https://repo.continuum.io/pkgs/r -c https://repo.continuum.io/pkgs/pro --python=${PYTHON_VERSION} conda run_cmd ${CONDA_FOLDER}/bin/conda build --override-channels -c ${CONDA_CHANNEL} -c https://repo.continuum.io/pkgs/main -c https://repo.continuum.io/pkgs/free -c https://repo.continuum.io/pkgs/r -c https://repo.continuum.io/pkgs/pro --python=${PYTHON_VERSION} conda
fi fi
# Copy the .tar.bz2 and urls.txt # Move the cache to conda env folder to cache it
if [ "${OSNAME}" == "linux" ]; then if [ "${OSNAME}" == "linux" ]; then
mkdir -p ${CONDA_ENVS_PATH}/.pkgs mkdir -p ${CONDA_ENVS_PATH}/.pkgs
touch ${CONDA_ENVS_PATH}/.pkgs/urls touch ${CONDA_ENVS_PATH}/.pkgs/urls
touch ${CONDA_ENVS_PATH}/.pkgs/urls.txt touch ${CONDA_ENVS_PATH}/.pkgs/urls.txt
fi fi
merge_conda_cache ${CONDA_ENVS_PATH}/.pkgs ${CONDA_FOLDER}/pkgs merge_conda_cache ${CONDA_ENVS_PATH}/.pkgs ${CONDA_FOLDER}/pkgs
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment