mirror of
https://github.com/aquasecurity/kube-bench.git
synced 2024-12-22 22:58:07 +00:00
No need to load config just to check if components are running.
This also allows for there to be no master.yaml file, for environments where such a thing doesn’t need to exist
This commit is contained in:
parent
596dae03d9
commit
de623220e1
@ -199,7 +199,6 @@ func loadConfig(nodetype check.NodeType) string {
|
|||||||
|
|
||||||
// isMaster verify if master components are running on the node.
|
// isMaster verify if master components are running on the node.
|
||||||
func isMaster() bool {
|
func isMaster() bool {
|
||||||
_ = loadConfig(check.MASTER)
|
|
||||||
glog.V(2).Info("Checking if the current node is running master components")
|
glog.V(2).Info("Checking if the current node is running master components")
|
||||||
masterConf := viper.Sub(string(check.MASTER))
|
masterConf := viper.Sub(string(check.MASTER))
|
||||||
components, err := getBinaries(masterConf)
|
components, err := getBinaries(masterConf)
|
||||||
|
Loading…
Reference in New Issue
Block a user