mirror of
https://github.com/k8snetworkplumbingwg/multus-cni.git
synced 2025-09-09 04:42:15 +00:00
Fix golint error and make it enable again in travis
This commit is contained in:
committed by
Tomofumi Hayashi
parent
33f077ce1b
commit
2fe42c11c7
@@ -28,6 +28,7 @@ const (
|
||||
checkPointfile = "/var/lib/kubelet/device-plugins/kubelet_internal_checkpoint"
|
||||
)
|
||||
|
||||
// PodDevicesEntry maps PodUID, resource name and allocated device id
|
||||
type PodDevicesEntry struct {
|
||||
PodUID string
|
||||
ContainerName string
|
||||
@@ -41,7 +42,7 @@ type checkpointData struct {
|
||||
RegisteredDevices map[string][]string
|
||||
}
|
||||
|
||||
type Data struct {
|
||||
type checkpointFileData struct {
|
||||
Data checkpointData
|
||||
Checksum uint64
|
||||
}
|
||||
@@ -70,7 +71,7 @@ func getCheckpoint(filePath string) (types.ResourceClient, error) {
|
||||
// getPodEntries gets all Pod device allocation entries from checkpoint file
|
||||
func (cp *checkpoint) getPodEntries() error {
|
||||
|
||||
cpd := &Data{}
|
||||
cpd := &checkpointFileData{}
|
||||
rawBytes, err := ioutil.ReadFile(cp.fileName)
|
||||
if err != nil {
|
||||
return logging.Errorf("getPodEntries(): error reading file %s\n%v\n", checkPointfile, err)
|
||||
|
Reference in New Issue
Block a user