Created
July 9, 2019 23:58
-
-
Save fopina/eea83d290f634566b2e68e31d9ba6a74 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- hosts: all | |
gather_facts: True | |
become: True | |
roles: | |
- role: fluentbit | |
fluentbit_inputs: | |
- systemd: | |
- Tag: docker | |
- Systemd_Filter: _SYSTEMD_UNIT=docker.service | |
- cpu: | |
- Tag: cpu | |
- Interval_Sec: 10 | |
- mem: | |
- Tag: mem | |
- Interval_Sec: 10 | |
fluentbit_filters: | |
- record_modifier: | |
- Match: 'docker' | |
- Whitelist_key: MESSAGE | |
- Whitelist_key: CONTAINER_ID | |
- Whitelist_key: CONTAINER_NAME | |
- record_modifier: | |
- Match: 'cpu' | |
- Whitelist_key: cpu_p | |
- Whitelist_key: user_p | |
- Whitelist_key: system_p | |
- record_modifier: | |
- Match: 'mem' | |
- Whitelist_key: Mem.used | |
- Whitelist_key: Swap.used | |
- record_modifier: | |
- Match: '*' | |
- Record: 'hostname ${HOSTNAME}' | |
fluentbit_outputs: | |
- stackdriver: | |
- google_service_credentials: /etc/gcreds.json | |
- Match: '*' | |
tasks: | |
- name: copy GCP service credentials | |
copy: | |
src: google_credentials.json | |
dest: /etc/gcreds.json | |
mode: 0400 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment