Skip to content

Commit 396c283

Browse files
authored
Merge pull request #270 from Lion-Wei/fix-version
fix node-problem-detector --version to not require monitors specify
2 parents 4880be8 + 4110e53 commit 396c283

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cmd/node_problem_detector.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,15 +60,15 @@ func main() {
6060

6161
pflag.Parse()
6262

63-
npdo.SetNodeNameOrDie()
64-
65-
npdo.ValidOrDie()
66-
6763
if npdo.PrintVersion {
6864
version.PrintVersion()
6965
os.Exit(0)
7066
}
7167

68+
npdo.SetNodeNameOrDie()
69+
70+
npdo.ValidOrDie()
71+
7272
monitors := make(map[string]types.Monitor)
7373
for _, config := range npdo.SystemLogMonitorConfigPaths {
7474
if _, ok := monitors[config]; ok {

0 commit comments

Comments
 (0)