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

New API configuration behavior on 3.11 #77

Closed
6 tasks done
xr09 opened this issue Dec 30, 2019 · 2 comments
Closed
6 tasks done

New API configuration behavior on 3.11 #77

xr09 opened this issue Dec 30, 2019 · 2 comments
Assignees
Milestone

Comments

@xr09
Copy link
Contributor

xr09 commented Dec 30, 2019

Description

Starting with v3.11 the Wazuh plugin for Kibana has a new behavior when upgrading.

Documented here: wazuh/wazuh-dashboard-plugins#1465

The former config.yml got renamed to wazuh.yml, which brought some internal changes as well, the API settings will no longer be stored in the Elastic index named .wazuh, these settings got migrated to wazuh.yml.

The new behavior is like this:

  • The first time booting 3.11 Wazuh plugin detects if there's an .wazuh index and moves it to wazuh.yml, this info gets deleted from Elastic.

  • On the following restart cycles there will be no .wazuh index

Proposed workflow

Following a declarative approach we propose to always delete the .wazuh index if exists and write API settings to wazuh.yml. In the case the user updated the password, then the cookbook will override it in both the API and Kibana settings.

Tasks

  • Implement required changes to make Chef delete the .wazuh index

  • Add required variables to configure the API credentials in the wazuh.yml file

  • Create template to render the wazuh.yml file

Tests

The following scenarios should be tested:

  • New deployment
  • Upgrading from 3.10 to 3.11 (no other changes)
  • Upgrading from 3.10 to 3.11 (changing API settings)
@jm404 jm404 added this to the Sprint - 105 milestone Dec 30, 2019
@jm404 jm404 self-assigned this Dec 30, 2019
@jm404
Copy link
Contributor

jm404 commented Dec 30, 2019

Implement changes to configure Wazuh API credentials

The Chef code now checks for existent .wazuh index and removes it in case it exists. Also, a template block has been added to configure the Wazuh API credentials for Kibana:

image

Commit: 0cdeba6

@jm404
Copy link
Contributor

jm404 commented Dec 31, 2019

Done in #78

@jm404 jm404 closed this as completed Dec 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants