mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 02:15:43 +03:00
Return when nomad syslog command has invalid number of argument
This commit is contained in:
@@ -27,6 +27,7 @@ func (s *SyslogPluginCommand) Synopsis() string {
|
||||
func (s *SyslogPluginCommand) Run(args []string) int {
|
||||
if len(args) == 0 {
|
||||
s.Ui.Error("log output file isn't provided")
|
||||
return 1
|
||||
}
|
||||
logFileName := args[0]
|
||||
stdo, err := os.OpenFile(logFileName, os.O_CREATE|os.O_RDWR|os.O_APPEND, 0666)
|
||||
|
||||
Reference in New Issue
Block a user