mirror of
https://github.com/moby/buildkit.git
synced 2026-06-30 19:57:39 +00:00
Merge pull request #5769 from tonistiigi/cdi-fsnotify-fix
vendor: cdi v0.8.1 for panic fix
This commit is contained in:
@@ -1067,6 +1067,13 @@ func getCDIManager(cfg config.CDIConfig) (*cdidevices.Manager, error) {
|
||||
if err := cdiCache.Refresh(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if errs := cdiCache.GetErrors(); len(errs) > 0 {
|
||||
for dir, errs := range errs {
|
||||
for _, err := range errs {
|
||||
bklog.L.Warnf("CDI setup error %v: %+v", dir, err)
|
||||
}
|
||||
}
|
||||
}
|
||||
return cdiCache, nil
|
||||
}()
|
||||
if err != nil {
|
||||
|
||||
2
go.mod
2
go.mod
@@ -108,7 +108,7 @@ require (
|
||||
google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1
|
||||
google.golang.org/protobuf v1.35.2
|
||||
kernel.org/pub/linux/libs/security/libcap/cap v1.2.73
|
||||
tags.cncf.io/container-device-interface v0.8.0
|
||||
tags.cncf.io/container-device-interface v0.8.1
|
||||
)
|
||||
|
||||
require (
|
||||
|
||||
4
go.sum
4
go.sum
@@ -590,7 +590,7 @@ kernel.org/pub/linux/libs/security/libcap/psx v1.2.73/go.mod h1:+l6Ee2F59XiJ2I6W
|
||||
sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8=
|
||||
sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E=
|
||||
sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY=
|
||||
tags.cncf.io/container-device-interface v0.8.0 h1:8bCFo/g9WODjWx3m6EYl3GfUG31eKJbaggyBDxEldRc=
|
||||
tags.cncf.io/container-device-interface v0.8.0/go.mod h1:Apb7N4VdILW0EVdEMRYXIDVRZfNJZ+kmEUss2kRRQ6Y=
|
||||
tags.cncf.io/container-device-interface v0.8.1 h1:c0jN4Mt6781jD67NdPajmZlD1qrqQyov/Xfoab37lj0=
|
||||
tags.cncf.io/container-device-interface v0.8.1/go.mod h1:Apb7N4VdILW0EVdEMRYXIDVRZfNJZ+kmEUss2kRRQ6Y=
|
||||
tags.cncf.io/container-device-interface/specs-go v0.8.0 h1:QYGFzGxvYK/ZLMrjhvY0RjpUavIn4KcmRmVP/JjdBTA=
|
||||
tags.cncf.io/container-device-interface/specs-go v0.8.0/go.mod h1:BhJIkjjPh4qpys+qm4DAYtUyryaTDg9zris+AczXyws=
|
||||
|
||||
2
vendor/modules.txt
vendored
2
vendor/modules.txt
vendored
@@ -1125,7 +1125,7 @@ kernel.org/pub/linux/libs/security/libcap/psx
|
||||
## explicit; go 1.12
|
||||
sigs.k8s.io/yaml
|
||||
sigs.k8s.io/yaml/goyaml.v2
|
||||
# tags.cncf.io/container-device-interface v0.8.0
|
||||
# tags.cncf.io/container-device-interface v0.8.1
|
||||
## explicit; go 1.20
|
||||
tags.cncf.io/container-device-interface/internal/validation
|
||||
tags.cncf.io/container-device-interface/internal/validation/k8s
|
||||
|
||||
8
vendor/tags.cncf.io/container-device-interface/pkg/cdi/cache.go
generated
vendored
8
vendor/tags.cncf.io/container-device-interface/pkg/cdi/cache.go
generated
vendored
@@ -564,6 +564,14 @@ func (w *watch) update(dirErrors map[string]error, removed ...string) bool {
|
||||
update bool
|
||||
)
|
||||
|
||||
// If we failed to create an fsnotify.Watcher we have a nil watcher here
|
||||
// (but with autoRefresh left on). One known case when this can happen is
|
||||
// if we have too many open files. In that case we always return true and
|
||||
// force a refresh.
|
||||
if w.watcher == nil {
|
||||
return true
|
||||
}
|
||||
|
||||
for dir, ok = range w.tracked {
|
||||
if ok {
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user