add nvidia gpu drivers to k3s
This commit is contained in:
parent
1aa03a7d37
commit
4f90405092
2
hosts
2
hosts
|
@ -23,6 +23,8 @@ all:
|
||||||
vfio_pci_ids:
|
vfio_pci_ids:
|
||||||
- '1002:731f' # Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT]
|
- '1002:731f' # Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT]
|
||||||
- '1002:ab38' # Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 HDMI Audio
|
- '1002:ab38' # Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 HDMI Audio
|
||||||
|
- '10de:13f1' # VGA compatible controller [0300]: NVIDIA Corporation GM204GL [Quadro M4000]
|
||||||
|
- '10de:0fbb' # Audio device [0403]: NVIDIA Corporation GM204 High Definition Audio Controller
|
||||||
bastion:
|
bastion:
|
||||||
hosts:
|
hosts:
|
||||||
bastion:
|
bastion:
|
||||||
|
|
|
@ -1 +1,2 @@
|
||||||
platform: lxc
|
platform: lxc
|
||||||
|
nvidia_driver_branch: 550
|
|
@ -7,3 +7,24 @@
|
||||||
group: root
|
group: root
|
||||||
mode: 0755
|
mode: 0755
|
||||||
notify: reboot
|
notify: reboot
|
||||||
|
|
||||||
|
# Begin nvidia
|
||||||
|
# https://dev.to/mweibel/add-nvidia-gpu-support-to-k3s-with-containerd-4j17
|
||||||
|
- name: Download nvidia repository gpg key
|
||||||
|
get_url:
|
||||||
|
url: https://nvidia.github.io/libnvidia-container/gpgkey
|
||||||
|
dest: /usr/share/keyrings/nvidia-container-toolkit-keyring.asc
|
||||||
|
|
||||||
|
- name: Add nvidia repository
|
||||||
|
apt_repository:
|
||||||
|
repo: deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.asc] https://nvidia.github.io/libnvidia-container/stable/deb/$(ARCH) /
|
||||||
|
|
||||||
|
- name: Install nvidia drivers and nvidia container toolkit
|
||||||
|
apt:
|
||||||
|
update_cache: true
|
||||||
|
name:
|
||||||
|
- linux-modules-nvidia-{{ nvidia_driver_branch }}-server-generic
|
||||||
|
- nvidia-utils-{{ nvidia_driver_branch }}-server
|
||||||
|
- nvidia-container-toolkit
|
||||||
|
notify: reboot
|
||||||
|
# End nvidia
|
|
@ -1 +1 @@
|
||||||
deb http://download.proxmox.com/debian/pve bullseye pve-no-subscription
|
deb http://download.proxmox.com/debian/pve bookworm pve-no-subscription
|
||||||
|
|
|
@ -1,9 +1,3 @@
|
||||||
- name: Install linux-tools
|
|
||||||
apt:
|
|
||||||
update_cache: true
|
|
||||||
name:
|
|
||||||
- linux-tools-generic
|
|
||||||
|
|
||||||
- name: Enable IOMMU
|
- name: Enable IOMMU
|
||||||
lineinfile:
|
lineinfile:
|
||||||
path: /etc/default/grub
|
path: /etc/default/grub
|
||||||
|
|
Loading…
Reference in New Issue