mirror of
				https://github.com/ClusterCockpit/cc-metric-collector.git
				synced 2025-11-04 02:35:07 +01:00 
			
		
		
		
	Avoid vet warning struct field commands has json tag but is not exported
This commit is contained in:
		@@ -15,7 +15,7 @@ import (
 | 
			
		||||
const LUSTREFILE = `/proc/fs/lustre/llite/lnec-XXXXXX/stats`
 | 
			
		||||
 | 
			
		||||
type LustreCollectorConfig struct {
 | 
			
		||||
	procfiles      []string `json:"procfiles"`
 | 
			
		||||
	Procfiles      []string `json:"procfiles"`
 | 
			
		||||
	ExcludeMetrics []string `json:"exclude_metrics"`
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@@ -47,7 +47,7 @@ func (m *LustreCollector) Init(config []byte) error {
 | 
			
		||||
		"statfs":           {"statfs": 1},
 | 
			
		||||
		"inode_permission": {"inode_permission": 1}}
 | 
			
		||||
	m.devices = make([]string, 0)
 | 
			
		||||
	for _, p := range m.config.procfiles {
 | 
			
		||||
	for _, p := range m.config.Procfiles {
 | 
			
		||||
		_, err := ioutil.ReadFile(p)
 | 
			
		||||
		if err == nil {
 | 
			
		||||
			m.devices = append(m.devices, p)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user