From f5ce63b6387b1917c21ce752851fa3c5a00bc7d4 Mon Sep 17 00:00:00 2001 From: Benjamin Bertrand <benjamin.bertrand@esss.se> Date: Wed, 25 Apr 2018 08:14:31 +0200 Subject: [PATCH] Switch to artifactory channels 1. Artifactory hosts a mirror of: - conda-forge - anaconda-main (this is the only channel from defaults that we care about) We also add the ics-conda channel. We probably want to allow people to add extra channels in the future. 2. Remove the user condarc file. The default configuration should be done at system level. --- files/system_condarc | 9 ++++++++- files/user_condarc | 4 ---- tasks/main.yml | 11 +++-------- 3 files changed, 11 insertions(+), 13 deletions(-) delete mode 100644 files/user_condarc diff --git a/files/system_condarc b/files/system_condarc index 54012c6..d89af5a 100644 --- a/files/system_condarc +++ b/files/system_condarc @@ -1,2 +1,9 @@ pinned_packages: - - defaults::conda + - anaconda-main::conda + - anaconda-main::conda-build +channel_alias: https://artifactory.esss.lu.se/artifactory +channels: + - ics-conda + - conda-forge + - anaconda-main +auto_update_conda: False diff --git a/files/user_condarc b/files/user_condarc deleted file mode 100644 index 856c200..0000000 --- a/files/user_condarc +++ /dev/null @@ -1,4 +0,0 @@ -auto_update_conda: False -channels: - - conda-forge - - defaults diff --git a/tasks/main.yml b/tasks/main.yml index 07c5a44..ccaa343 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -83,18 +83,13 @@ dest: /etc/profile.d/conda.sh state: link -- name: copy condarc files +- name: copy condarc file copy: - src: "{{ item.src }}" - dest: "{{ item.dest }}/.condarc" + src: system_condarc + dest: /opt/conda/.condarc owner: conda group: users mode: 0644 - with_items: - - src: user_condarc - dest: /home/conda - - src: system_condarc - dest: /opt/conda # See https://github.com/conda/conda/issues/6576 - name: create empty environments.txt due to conda bug -- GitLab