mirror of
https://github.com/hanzoai/visor.git
synced 2026-09-24 17:04:14 +00:00
Setting NVIDIA_DRIVER_CAPABILITIES=all with --nvproxy-allowed-driver-capabilities=all,profiling crashed runsc on startup (exit status 2): NVIDIAFlags() panicked on CapProfiling, which has no nvidia-container-cli flag. Privileged caps (CapProfiling, CapFabricIMEXManagement) are enforced internally by nvproxy, so NVIDIAFlags() now skips them instead of panicking. Adds a regression test.
30 lines
519 B
Python
30 lines
519 B
Python
load("//tools:defs.bzl", "go_library", "go_test")
|
|
|
|
package(default_applicable_licenses = ["//:license"])
|
|
|
|
licenses(["notice"])
|
|
|
|
go_library(
|
|
name = "nvconf",
|
|
srcs = [
|
|
"caps.go",
|
|
"hostsettings.go",
|
|
"nvconf.go",
|
|
"version.go",
|
|
],
|
|
visibility = [
|
|
"//pkg/sentry:internal",
|
|
"//tools:__subpackages__",
|
|
],
|
|
deps = [
|
|
"//pkg/log",
|
|
],
|
|
)
|
|
|
|
go_test(
|
|
name = "nvconf_test",
|
|
size = "small",
|
|
srcs = ["caps_test.go"],
|
|
library = ":nvconf",
|
|
)
|