Skip to content
This repository has been archived by the owner on May 25, 2022. It is now read-only.

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
rockb1017 committed Aug 27, 2021
1 parent c12d0c2 commit f296a3f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 3 additions & 3 deletions operator/builtin/input/journald/journald.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func NewJournaldInputConfig(operatorID string) *JournaldInputConfig {
return &JournaldInputConfig{
InputConfig: helper.NewInputConfig(operatorID, "journald_input"),
StartAt: "end",
Priority: "info",
Priority: "info",
}
}

Expand All @@ -55,7 +55,7 @@ type JournaldInputConfig struct {
Directory *string `mapstructure:"directory,omitempty" json:"directory,omitempty" yaml:"directory,omitempty"`
Files []string `mapstructure:"files,omitempty" json:"files,omitempty" yaml:"files,omitempty"`
StartAt string `mapstructure:"start_at,omitempty" json:"start_at,omitempty" yaml:"start_at,omitempty"`
Units []string `mapstructure:"units,omitempty" json:"units,omitempty" yaml:"units,omitempty"`
Units []string `mapstructure:"units,omitempty" json:"units,omitempty" yaml:"units,omitempty"`
Priority string `mapstructure:"priority,omitempty" json:"priority,omitempty" yaml:"priority,omitempty"`
}

Expand Down Expand Up @@ -86,7 +86,7 @@ func (c JournaldInputConfig) Build(buildContext operator.BuildContext) ([]operat
}

for _, unit := range c.Units {
args = append(args, "--unit=", unit)
args = append(args, "--unit", unit)
}

args = append(args, "--priority", c.Priority)
Expand Down
1 change: 1 addition & 0 deletions operator/builtin/input/journald/journald_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ func TestJournaldInputConfig(t *testing.T) {
input := map[string]interface{}{
"id": "my_journald_input",
"type": "journald_input",
"priority": "info",
"start_at": "end",
"write_to": "$body.to",
"attributes": map[string]interface{}{},
Expand Down

0 comments on commit f296a3f

Please sign in to comment.