Skip to content

Commit

Permalink
Fix nvidia toolkit check (#33)
Browse files Browse the repository at this point in the history
* fix: nvidia toolkit check

* add: Updated the nvidia driver branch

* Improved container inspect

---------

Co-authored-by: gioacchino.vino <[email protected]>
  • Loading branch information
jvino and gioacchino.vino authored Jan 26, 2024
1 parent 4995ae6 commit c743f53
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion tasks/jupyterhub-partitioned-gpus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@
- ' running_containers_ids = client.containers()'
- ' for id in running_containers_ids:'
- ' my_c = client.inspect_container(id["Id"])'
- ' if my_c["HostConfig"]["DeviceRequests"] is not None:'
- ' try: '
- ' gpu_uuid.add(my_c["HostConfig"]["DeviceRequests"][0]["DeviceIDs"][0])'
- ' except: '
- ' pass'
- ' return gpu_uuid'
- 'def get_available_gpu_ids():'
- ' all_gpus_ids = get_all_gpus_ids()'
Expand Down
4 changes: 2 additions & 2 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
ansible.builtin.include_tasks: gpu-support.yaml
vars:
enable_gpu: true
gpu_support_role: git+https://baltig.infn.it/infn-cloud/ansible-role-gpu-support,v1.2.1
nvidia_driver_branch: "515"
gpu_support_role: git+https://baltig.infn.it/infn-cloud/ansible-role-gpu-support,v1.2.4
nvidia_driver_branch: "535"
nvidia_driver_ubuntu_install_from_cuda_repo: true
nvidia_driver_skip_reboot: true
when: (use_gpu | bool)
Expand Down

0 comments on commit c743f53

Please sign in to comment.