Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultListenerConfig = ListenerConfig{ ListenProtocol: st.DefaultProtocol, IdleTimeout: st.DefaultIdleTimeout, MaxMessageLength: st.DefaultMaxMessageLength, SyslogFormat: scrapeconfig.SyslogFormatRFC5424, }
DefaultListenerConfig provides the default arguments for a syslog listener.
Functions ¶
This section is empty.
Types ¶
type Arguments ¶
type Arguments struct {
SyslogListeners []ListenerConfig `alloy:"listener,block"`
ForwardTo []loki.LogsReceiver `alloy:"forward_to,attr"`
RelabelRules alloy_relabel.Rules `alloy:"relabel_rules,attr,optional"`
}
Arguments holds values which are used to configure the loki.source.syslog component.
type Component ¶
type Component struct {
// contains filtered or unexported fields
}
Component implements the loki.source.syslog component.
func (*Component) LiveDebugging ¶ added in v1.13.0
func (*Component) LiveDebugging()
LiveDebugging implements component.LiveDebugging.
type ListenerConfig ¶
type ListenerConfig struct {
ListenAddress string `alloy:"address,attr"`
ListenProtocol string `alloy:"protocol,attr,optional"`
IdleTimeout time.Duration `alloy:"idle_timeout,attr,optional"`
LabelStructuredData bool `alloy:"label_structured_data,attr,optional"`
Labels map[string]string `alloy:"labels,attr,optional"`
UseIncomingTimestamp bool `alloy:"use_incoming_timestamp,attr,optional"`
UseRFC5424Message bool `alloy:"use_rfc5424_message,attr,optional"`
RFC3164DefaultToCurrentYear bool `alloy:"rfc3164_default_to_current_year,attr,optional"`
MaxMessageLength int `alloy:"max_message_length,attr,optional"`
TLSConfig config.TLSConfig `alloy:"tls_config,block,optional"`
SyslogFormat scrapeconfig.SyslogFormat `alloy:"syslog_format,attr,optional"`
RawFormatOptions *RawFormatOptions `alloy:"raw_format_options,block,optional"`
RFC3164CiscoComponents *RFC3164CiscoComponents `alloy:"rfc3164_cisco_components,block,optional"`
}
ListenerConfig defines a syslog listener.
func (ListenerConfig) Convert ¶
func (sc ListenerConfig) Convert() (*scrapeconfig.SyslogTargetConfig, error)
Convert is used to bridge between the Alloy and Promtail types.
func (*ListenerConfig) SetToDefault ¶
func (sc *ListenerConfig) SetToDefault()
SetToDefault implements syntax.Defaulter.
func (*ListenerConfig) Validate ¶
func (sc *ListenerConfig) Validate() error
Validate implements syntax.Validator.
type RFC3164CiscoComponents ¶ added in v1.13.0
type RFC3164CiscoComponents struct {
EnableAll bool `alloy:"enable_all,attr,optional"`
MessageCounter bool `alloy:"message_counter,attr,optional"`
SequenceNumber bool `alloy:"sequence_number,attr,optional"`
Hostname bool `alloy:"hostname,attr,optional"`
SecondFractions bool `alloy:"second_fractions,attr,optional"`
}
RFC3164CiscoComponents enables Cisco IOS log line parsing and configures what fields to parse.
func (*RFC3164CiscoComponents) Validate ¶ added in v1.13.0
func (sc *RFC3164CiscoComponents) Validate() error
type RawFormatOptions ¶ added in v1.13.0
type RawFormatOptions struct {
UseNullTerminatorDelimiter bool `alloy:"use_null_terminator_delimiter,attr,optional"`
}
RawFormatOptions is alloy syntax mapping to scrapeconfig.RawFormatOptions struct.
Click to show internal directories.
Click to hide internal directories.