Skip to content

Commit

Permalink
remove log format type check
Browse files Browse the repository at this point in the history
Option `LogConfig` is omitempty in config.
That means we allow `c.HostConfig.LogConfig` is nil. There is no
need to check the log type, we don't use it now in log sub
command, maybe in the furture.
  • Loading branch information
oiooj committed Apr 24, 2018
1 parent 2812ca0 commit 76ef07b
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions cli/logs.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,6 @@ func (lc *LogsCommand) runLogs(args []string) error {
return err
}

if !validDrivers[c.HostConfig.LogConfig.Type] {
return fmt.Errorf("\"logs\" command is supported only for \"json-file\" and \"journald\" logging drivers (got; %s)", c.HostConfig.LogConfig.Type)
}

opts := types.ContainerLogsOptions{
ShowStdout: true,
ShowStderr: true,
Expand Down

0 comments on commit 76ef07b

Please sign in to comment.