Skip to content
This repository has been archived by the owner on Nov 28, 2023. It is now read-only.

Ansible role to setup a journalbeat log shipper -- Arquivado por Foundation Platform dia 2023-11-28

License

Notifications You must be signed in to change notification settings

stone-payments/ansible-journalbeat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

stone-payments.journalbeat

Ansible role to setup a journalbeat log shipper.

Basic usage

You may use the simplified setup by overriding the defaults on defaults/main.yml like this, in a minimalistic setup that uses an ElasticSearch endpoint:

- name: install and configure journalbeat
  hosts: all
  roles: stone-payments.journalbeat
  vars:
    journalbeat_elasticsearch: true
    journalbeat_hosts: { "logs.example.com:9200" }

Basically, to use the role you select an endpoint type (elasticsearch, logstash, kafka or redis), set the corresponding variable to true and set the journalbeat_hosts variable to contain the endpoints' list that will have the logs delivered to.

You also have easily available additional metadata that may be filled with useful information, like this:

journalbeat_product: "webserver"
journalbeat_env: "production"
journalbeat_net: "dmz"
journalbeat_dc: "ny1"

Advanced settings

If you need to setup any variable that isn't contained in the easy setup, you may define it in the journalbeat_conf variable that holds a dict exactly the same as the YAML file used to configure the journalbeat daemon, and this variable will be joined to the default configuration. Like this:

journalbeat_conf:
  journalbeat:
    convert_to_numbers: false
  output:
    elasticsearch:
      path: "/somePath"

You may find the config file reference in the original project reference.

About

Ansible role to setup a journalbeat log shipper -- Arquivado por Foundation Platform dia 2023-11-28

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages