diff --git a/roles/crio/tasks/Debian.yml b/roles/crio/tasks/Debian.yml index 409213f5..d24a5947 100644 --- a/roles/crio/tasks/Debian.yml +++ b/roles/crio/tasks/Debian.yml @@ -20,4 +20,5 @@ apt: name: "nvidia-container-runtime" state: present - update_cache: yes \ No newline at end of file + update_cache: yes + environment: "{{ proxy_env | default({'http_proxy': '', 'https_proxy': '', 'no_proxy': ''}) }}" \ No newline at end of file diff --git a/roles/crio/tasks/RedHat.yml b/roles/crio/tasks/RedHat.yml index 227f2622..8bf2d85e 100644 --- a/roles/crio/tasks/RedHat.yml +++ b/roles/crio/tasks/RedHat.yml @@ -2,8 +2,10 @@ get_url: url: https://nvidia.github.io/nvidia-container-runtime/{{ ansible_distribution | lower }}{{ ansible_distribution_major_version }}/nvidia-container-runtime.repo dest: /etc/yum.repos.d/nvidia-container-runtime.repo + environment: "{{ proxy_env | default({'http_proxy': '', 'https_proxy': '', 'no_proxy': ''}) }}" - name: Install nvidia-container-runtime yum: name: nvidia-container-runtime - state: latest \ No newline at end of file + state: latest + environment: "{{ proxy_env | default({'http_proxy': '', 'https_proxy': '', 'no_proxy': ''}) }}" \ No newline at end of file diff --git a/roles/crio/tasks/SUSE.yml b/roles/crio/tasks/SUSE.yml index b8d1630f..b790c545 100644 --- a/roles/crio/tasks/SUSE.yml +++ b/roles/crio/tasks/SUSE.yml @@ -2,6 +2,7 @@ ansible.builtin.rpm_key: state: present key: https://nvidia.github.io/libnvidia-container/gpgkey + environment: "{{ proxy_env | default({'http_proxy': '', 'https_proxy': '', 'no_proxy': ''}) }}" - name: Add specified repository into sources community.general.zypper_repository: @@ -12,4 +13,5 @@ community.general.zypper: name: nvidia-container-runtime state: latest - update_cache: yes \ No newline at end of file + update_cache: yes + environment: "{{ proxy_env | default({'http_proxy': '', 'https_proxy': '', 'no_proxy': ''}) }}" \ No newline at end of file