Restructure repository (#66)

This commit is contained in:
Jesús Linares 2018-10-04 12:40:10 +02:00 committed by GitHub
parent 397dcb59d6
commit 1bd21e381b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
103 changed files with 109 additions and 38 deletions

23
CHANGELOG.md Normal file
View File

@ -0,0 +1,23 @@
# Change Log
All notable changes to this project will be documented in this file.
## [v3.7.0]
### Changed
- Repository restructure.
## [v3.6.0]
Ansible starting point.
Roles:
- Elastic Stack:
- ansible-elasticsearch: This role is prepared to install elasticsearch on the host that runs it.
- ansible-logstash: This role involves the installation of logstash on the host that runs it.
- ansible-kibana: Using this role we will install Kibana on the host that runs it.
- Wazuh:
- ansible-filebeat: This role is prepared to install filebeat on the host that runs it.
- ansible-wazuh-manager: With this role we will install Wazuh manager and Wazuh API on the host that runs it.
- ansible-wazuh-agent: Using this role we will install Wazuh agent on the host that runs it and is able to register it.

View File

@ -1,4 +1,4 @@
# Wazuh Ansible playbooks # Wazuh-Ansible
[![Slack](https://img.shields.io/badge/slack-join-blue.svg)](https://goo.gl/forms/M2AoZC4b2R9A9Zy12) [![Slack](https://img.shields.io/badge/slack-join-blue.svg)](https://goo.gl/forms/M2AoZC4b2R9A9Zy12)
[![Email](https://img.shields.io/badge/email-join-blue.svg)](https://groups.google.com/forum/#!forum/wazuh) [![Email](https://img.shields.io/badge/email-join-blue.svg)](https://groups.google.com/forum/#!forum/wazuh)
@ -9,19 +9,66 @@ These playbooks install and configure Wazuh agent, manager and Elastic Stack.
## Documentation ## Documentation
* [Full documentation](http://documentation.wazuh.com)
* [Wazuh Ansible documentation](https://documentation.wazuh.com/current/deploying-with-ansible/index.html) * [Wazuh Ansible documentation](https://documentation.wazuh.com/current/deploying-with-ansible/index.html)
* [Full documentation](http://documentation.wazuh.com)
### Based on previous work from dj-wasabi ## Directory structure
https://github.com/dj-wasabi/ansible-ossec-server ├── wazuh-ansible
│ ├── roles
│ │ ├── elastic-stack
│ │ │ ├── ansible-elasticsearch
│ │ │ ├── ansible-logstash
│ │ │ ├── ansible-kibana
│ │
│ │ ├── wazuh
│ │ │ ├── ansible-filebeat
│ │ │ ├── ansible-wazuh-manager
│ │ │ ├── ansible-wazuh-agent
│ │
│ │ ├── ansible-galaxy
│ │ │ ├── meta
│ ├── playbooks
│ │ ├── wazuh-agent.yml
│ │ ├── wazuh-elastic.yml
│ │ ├── wazuh-elastic_stack-distributed.yml
│ │ ├── wazuh-elastic_stack-single.yml
│ │ ├── wazuh-kibana.yml
│ │ ├── wazuh-logstash.yml
│ │ ├── wazuh-manager.yml
│ ├── README.md
│ ├── VERSION
│ ├── CHANGELOG.md
## Branches
* `stable` branch on correspond to the last Wazuh-Ansible stable version.
* `master` branch contains the latest code, be aware of possible bugs on this branch.
## Contribute
If you want to contribute to our repository, please fork our Github repository and submit a pull request.
If you are not familiar with Github, you can also share them through [our users mailing list](https://groups.google.com/d/forum/wazuh), to which you can subscribe by sending an email to `wazuh+subscribe@googlegroups.com`.
### Modified by Wazuh ### Modified by Wazuh
The playbooks have been modified by Wazuh, including some specific requirements, templates and configuration to improve integration with Wazuh ecosystem. The playbooks have been modified by Wazuh, including some specific requirements, templates and configuration to improve integration with Wazuh ecosystem.
## Credits and Thank you
## References Based on previous work from dj-wasabi.
https://github.com/dj-wasabi/ansible-ossec-server
## License and copyright
WAZUH
Copyright (C) 2016-2018 Wazuh Inc. (License GPLv2)
## Web references
* [Wazuh website](http://wazuh.com) * [Wazuh website](http://wazuh.com)
* [OSSEC project website](http://ossec.github.io)

2
VERSION Normal file
View File

@ -0,0 +1,2 @@
WAZUH-ANSIBLE_VERSION="v3.7.0"
REVISION="3700"

View File

@ -1,9 +1,9 @@
- hosts: all:!wazuh-manager - hosts: <your wazuh agents hosts>
roles: roles:
- ansible-wazuh-agent - /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-wazuh-agent
vars: vars:
wazuh_managers: wazuh_managers:
- address: 127.0.0.1 - address: <your manager IP>
port: 1514 port: 1514
protocol: udp protocol: udp
api_port: 55000 api_port: 55000

View File

@ -0,0 +1,3 @@
- hosts: <your elasticsearch host>
roles:
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-elasticsearch, elasticsearch_network_host: 'your elasticsearch IP' }

View File

@ -0,0 +1,9 @@
- hosts: <your wazuh server host>
roles:
- role: /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-wazuh-manager
- { role: /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-filebeat, filebeat_output_logstash_hosts: 'your elastic stack server IP' }
- hosts: <your elastic stack server host>
roles:
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-elasticsearch, elasticsearch_network_host: 'localhost' }
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-logstash, logstash_input_beats: true, elasticsearch_network_host: 'localhost' }
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-kibana, elasticsearch_network_host: 'localhost' }

View File

@ -0,0 +1,6 @@
- hosts: <your single server host>
roles:
- { role: /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-wazuh-manager }
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-elasticsearch, elasticsearch_network_host: 'localhost' }
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-logstash, elasticsearch_network_host: 'localhost' }
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-kibana, elasticsearch_network_host: 'localhost' }

View File

@ -0,0 +1,3 @@
- hosts: <your kibana host>
roles:
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-kibana, elasticsearch_network_host: 'your elasticsearch IP' }

View File

@ -0,0 +1,3 @@
- hosts: <your logstash host>
roles:
- { role: /etc/ansible/roles/wazuh-ansible/roles/elastic-stack/ansible-logstash, elasticsearch_network_host: 'localhost' }

View File

@ -0,0 +1,4 @@
- hosts: <your wazuh server host>
roles:
- role: /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-wazuh-manager
- { role: /etc/ansible/roles/wazuh-ansible/roles/wazuh/ansible-filebeat, filebeat_output_logstash_hosts: 'your logstash IP' }

View File

@ -1,3 +0,0 @@
- hosts: elasticsearch
roles:
- { role: ansible-role-elasticsearch, elasticsearch_network_host: '192.168.33.182' }

View File

@ -1,9 +0,0 @@
- hosts: wazuh-manager
roles:
- role: ansible-wazuh-manager
- { role: ansible-role-filebeat, filebeat_output_logstash_hosts: '192.168.212.185:5000' }
- hosts: elastic_stack
roles:
- { role: ansible-role-elasticsearch, elasticsearch_network_host: 'localhost' }
- { role: ansible-role-logstash, logstash_input_beats: true, elasticsearch_network_host: 'localhost' }
- { role: ansible-role-kibana, elasticsearch_network_host: 'localhost' }

View File

@ -1,7 +0,0 @@
- hosts: wazuh-ELK-single
roles:
- { role: ansible-wazuh-manager }
- { role: ansible-role-elasticsearch, elasticsearch_network_host: 'localhost' }
- { role: ansible-role-logstash, elasticsearch_network_host: 'localhost' }
- { role: ansible-role-kibana, elasticsearch_network_host: 'localhost' }

Some files were not shown because too many files have changed in this diff Show More