This repository has been archived by the owner on Nov 1, 2018. It is now read-only.
forked from cyverse-archive/DE
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#15 installation working, no config just yet
- Loading branch information
1 parent
f70520f
commit fab7bcf
Showing
29 changed files
with
1,394 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
|
||
- hosts: elk | ||
sudo: yes | ||
roles: | ||
- elk-data | ||
- elk-elasticsearch |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
|
||
- hosts: systems | ||
sudo: yes | ||
roles: | ||
- support-filebeat |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
- hosts: elk | ||
become: true | ||
vars: | ||
logstash_install: "true" | ||
logstash_elasticsearch_host: "localhost:9200" | ||
logstash_plugins: | ||
- plugin: logstash-input-beats | ||
- plugin: logstash-output-elasticsearch | ||
logstash_version: "2.2" | ||
logstash_base_dir: "/opt/logstash" | ||
logstash_cfg_dir: "/etc/logstash/conf.d" | ||
logstash_clean_cfg_dir: true | ||
roles: | ||
- role: support-logstash-cfg |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
Elk-Data | ||
========= | ||
|
||
For deploying the service definitions for the ELK data container. | ||
|
||
Future features may be ES index management tasks | ||
|
||
All elastic search and kibana data is held in the data container. Executing | ||
this role _should not_ destroy any data that is already in the data container. | ||
|
||
Requirements | ||
------------ | ||
|
||
systemd | ||
|
||
Role Variables | ||
-------------- | ||
|
||
TBD | ||
|
||
Dependencies | ||
------------ | ||
|
||
N/A | ||
|
||
Example Playbook | ||
---------------- | ||
|
||
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: | ||
|
||
- hosts: servers | ||
roles: | ||
- { role: username.rolename, x: 42 } | ||
|
||
License | ||
------- | ||
|
||
BSD | ||
|
||
Author Information | ||
------------------ | ||
|
||
Jonathan Strootman, [email protected] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
--- | ||
# defaults file for elk-data | ||
enable_services: yes |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
--- | ||
# tasks file for elk-data | ||
- name: pull elk images | ||
shell: docker pull {{ elk.data.image_name }} | ||
register: docker_pull_v | ||
changed_when: docker_pull_v.stdout.find('Image is up to date') == -1 | ||
tags: | ||
- docker_pull | ||
- docker_pull_elk_data | ||
|
||
- name: place Systemd service files | ||
template: src={{ elk.data.service_name }} dest=/usr/lib/systemd/system group=root owner=root mode=0664 | ||
register: service_file_v | ||
tags: | ||
- update_service_files | ||
- update_service_files_elk_data | ||
|
||
- name: Reload systemd | ||
shell: systemctl daemon-reload | ||
when: service_file_v.changed | ||
tags: | ||
- update_service_files | ||
- update_service_files_elk_data | ||
|
||
- name: enable elk data service | ||
service: name={{elk.data.service_name}} enabled={{enable_services}} | ||
when: service_file_v.changed | ||
tags: | ||
- enable_services | ||
- enable_data | ||
|
||
- name: Container exists | ||
shell: "docker ps -aq -f 'name={{elk.data.container_name}}'" | ||
register: container_exists | ||
changed_when: container_exists.stdout == "" | ||
|
||
# Only restart if container doesn't exist. | ||
- name: restart elk data service | ||
service: name={{elk.data.service_name}} state=restarted | ||
when: container_exists.changed | ||
tags: | ||
- restart_services | ||
- restart_data | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
[Unit] | ||
Description={{elk.data.service_description}} | ||
BindsTo=docker.service | ||
PartOf=docker.service | ||
After=docker.service | ||
Requisite=docker.service | ||
|
||
[Service] | ||
Type=oneshot | ||
ExecStart=-/usr/bin/docker run --name {{elk.data.container_name}} -v /usr/share/elasticsearch/data/ {{elk.data.image_name}} | ||
|
||
SyslogIdentifier=elk-data |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
Elk-Kibana | ||
========= | ||
|
||
For deploying and configuring the Kibana instance for the DE ELK stack. | ||
|
||
Requirements | ||
------------ | ||
|
||
systemd | ||
|
||
Role Variables | ||
-------------- | ||
|
||
TBD | ||
|
||
Dependencies | ||
------------ | ||
|
||
N/A | ||
|
||
Example Playbook | ||
---------------- | ||
|
||
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: | ||
|
||
- hosts: servers | ||
roles: | ||
- { role: username.rolename, x: 42 } | ||
|
||
License | ||
------- | ||
|
||
BSD | ||
|
||
Author Information | ||
------------------ | ||
|
||
Jonathan Strootman, [email protected] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
--- | ||
# defaults file for elk-kibana | ||
enable_services: yes |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"title": "Top 25 User Activity", | ||
"description": "", | ||
"panelsJSON": "[{\"col\":1,\"id\":\"Top-25-Users-by-App-Submission\",\"row\":1,\"size_x\":4,\"size_y\":4,\"type\":\"visualization\"},{\"col\":1,\"id\":\"Top-25-Users-by-Login\",\"row\":5,\"size_x\":6,\"size_y\":3,\"type\":\"visualization\"},{\"col\":7,\"id\":\"Top-25-Users-by-Sharing-Activity\",\"row\":5,\"size_x\":6,\"size_y\":3,\"type\":\"visualization\"},{\"col\":5,\"id\":\"Top-25-Launched-Apps\",\"row\":1,\"size_x\":4,\"size_y\":4,\"type\":\"visualization\"},{\"id\":\"Total-Public-App-Submissions\",\"type\":\"visualization\",\"size_x\":3,\"size_y\":2,\"col\":9,\"row\":1},{\"id\":\"Total-Public-slash-Private-App-Submissions\",\"type\":\"visualization\",\"size_x\":3,\"size_y\":2,\"col\":9,\"row\":3}]", | ||
"timeRestore": false, | ||
"kibanaSavedObjectMeta": { | ||
"searchSourceJSON": "{\"filter\":[{\"query\":{\"query_string\":{\"query\":\"*\",\"analyze_wildcard\":true}}}]}" | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{"defaultIndex":"de-logs"} | ||
|
Oops, something went wrong.