Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
a0732ac9
Commit
a0732ac9
authored
Jul 24, 2014
by
e0d
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactoring to support multiple forward targets
parent
f54c73d2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
12 deletions
+27
-12
playbooks/roles/splunkforwarder/defaults/main.yml
+5
-2
playbooks/roles/splunkforwarder/templates/opt/splunkforwarder/etc/system/local/inputs.conf.j2
+10
-5
playbooks/roles/splunkforwarder/templates/opt/splunkforwarder/etc/system/local/outputs.conf.j2
+12
-5
No files found.
playbooks/roles/splunkforwarder/defaults/main.yml
View file @
a0732ac9
...
...
@@ -16,12 +16,15 @@
#
splunk_role_name
:
'
splunk'
SPLUNKFORWARDER_SERVER
:
'
localhost:9997'
SPLUNKFORWARDER_PACKAGE_URL
:
!!null
SPLUNKFORWARDER_DEB
:
!!null
SPLUNKFORWARDER_PASSWORD
:
!!null
SPLUNKFORWARDER_SERVERS
:
-
target_group
:
"
default_output_server"
server
:
"
localhost:9997"
default
:
true
SPLUNKFORWARDER_LOG_ITEMS
:
-
source
:
'
{{
COMMON_LOG_DIR
}}/lms'
recursive
:
true
...
...
playbooks/roles/splunkforwarder/templates/opt/splunkforwarder/etc/system/local/inputs.conf.j2
View file @
a0732ac9
# {{ ansible_managed }}
[default]
host = {{
ansible_hostname
}}
host = {{
ansible_hostname
}}
{% for loggable in SPLUNKFORWARDER_LOG_ITEMS%}
[monitor://{{
loggable.source
}}]
recursive = {{
loggable.recursive|default(false)
}}
[monitor://{{
loggable.source
}}]
recursive = {{
loggable.recursive|default(false)
}}
{% if loggable.sourcetype is defined %}
sourcetype = {{
loggable.sourcetype
}}
sourcetype = {{
loggable.sourcetype
}}
{% endif %}
{% if loggable.index is defined %}
index = {{loggable.index}}
index = {{ loggable.index }}
{% endif %}
{% if loggable._TCP_ROUTING is defined %}
_TCP_ROUTING = {{ loggable._TCP_ROUTING }}
{% endif %}
{% endfor %}
playbooks/roles/splunkforwarder/templates/opt/splunkforwarder/etc/system/local/outputs.conf.j2
View file @
a0732ac9
[tcpout]
defaultGroup = default_output_server
# {{ ansible_managed }}
[tcpout:default_output_server]
server = {{SPLUNKFORWARDER_SERVER}}
{% for server in SPLUNKFORWARDER_SERVERS|selectattr("default", "defined") %}
[tcpout]
defaultGroup = {{ server.target_group }}
[tcpout-server://{{ server.server }}]
{% endfor %}
[tcpout-server://{{SPLUNKFORWARDER_SERVER}}]
# forwarder receivers
{% for server in SPLUNKFORWARDER_SERVERS %}
[tcpout: {{ server.target_group }}]
server = {{ server.server }}
{% endfor %}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment