service:
  flush: 1
  daemon: Off
  log_level: info

pipeline:
  inputs:
    - name: collectd
      listen: 0.0.0.0
      port: 24224
      tag: collectd

    - name: mqtt
      listen: 0.0.0.0
      port: 1883
      tag: mqtt

  filters:
    - name: grep
      match: collectd
      regex: plugin exec

  outputs:
    - name: stdout
      match: '*'

    - name: loki
      match: '*'
      host: host
      port: 3100
      labels: job=fluentbit

    - name: pgsql
      match: '*'

      host: ${DATABASE_HOST}
      port: ${DATABASE_PORT}
      database: ${DATABASE_NAME}
      user: ${DATABASE_USER}
      password: ${DATABASE_PASS}
      table: logs
