diff --git a/ansible/roles/nvidia_container_toolkit_repo/defaults/main.yml b/ansible/roles/nvidia_container_toolkit_repo/defaults/main.yml index 278e2051..a0211c9c 100644 --- a/ansible/roles/nvidia_container_toolkit_repo/defaults/main.yml +++ b/ansible/roles/nvidia_container_toolkit_repo/defaults/main.yml @@ -13,7 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. +apt_keyring: /etc/apt/keyrings nvidia_gpg_key_url: https://nvidia.github.io/libnvidia-container/gpgkey nvidia_repo_url_deb: https://nvidia.github.io/libnvidia-container/stable/deb -nvidia_gpg_key_deb: /etc/apt/keyrings/nvidia-container-toolkit-keyring.asc +nvidia_gpg_key_deb: "{{ apt_keyring }}/nvidia-container-toolkit-keyring.asc" nvidia_repo_file_rpm: https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo diff --git a/ansible/roles/nvidia_container_toolkit_repo/tasks/os/debian.yml b/ansible/roles/nvidia_container_toolkit_repo/tasks/os/debian.yml index 8e606540..53f616b5 100644 --- a/ansible/roles/nvidia_container_toolkit_repo/tasks/os/debian.yml +++ b/ansible/roles/nvidia_container_toolkit_repo/tasks/os/debian.yml @@ -13,6 +13,12 @@ # See the License for the specific language governing permissions and # limitations under the License. +- name: Check and create keyring folder + ansible.builtin.file: + path: "{{ apt_keyring }}" + state: directory + mode: '0755' + - name: Collect Nvidia Container Repo GPG Key ansible.builtin.get_url: url: "{{ nvidia_gpg_key_url }}"