Jeremi Piotrowski 03925e1ca3 setup-nvidia: Make "current" symlink logic more robust
Users have reported that in some cases the nvidia.service fails because
/opt/nvidia/current is a directory and the symbolic link gets created inside
it. I have no idea how we get there, but to make the service robust in the face
of this kind of issue:

- remove the directory if it exists
- use `-T` with ln to ensure that symbolic link creation fails if `current` is a directory

Signed-off-by: Jeremi Piotrowski <jpiotrowski@microsoft.com>
2025-03-14 10:47:10 +01:00
..