Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create workflow to build packages #13

Closed
3 tasks done
Tracked by #9
AlexRuiz7 opened this issue Jul 11, 2024 · 1 comment · Fixed by #28 or wazuh/wazuh-indexer#360
Closed
3 tasks done
Tracked by #9

Create workflow to build packages #13

AlexRuiz7 opened this issue Jul 11, 2024 · 1 comment · Fixed by #28 or wazuh/wazuh-indexer#360
Assignees
Labels
level/task Task issue type/enhancement Enhancement issue

Comments

@AlexRuiz7
Copy link
Member

AlexRuiz7 commented Jul 11, 2024

Description

The new plugins for wazuh-indexer need to meet the requirements for the packages generation process (see https://github.com/wazuh/internal-devel-requests/issues/712). The plugins are self-compiled into a zip file by running the ./gradlew build command.

We need to generate the required GitHub Workflows to build packages for each of the plugins on demand. This tooling must be usable by wazuh-indexer's GitHub Workflow.

The goal of this issue, is to be able to generate a Wazuh Indexer packages with our plugins included. In order to do that, the wazuh-indexer build.yml workflow must invoke the build.yml workflow on this repository.

This repository will host several plugins under the plugins/ folder (see #4), so the plugin name needs to be an input parameter of the workflow. Once the plugins are successfully compiled, they are installed into Wazuh Indexer, as the rest of OpenSearch's plugins.

Implementation restrictions

  • Use of GitHub workflow.
  • Workflow is invoked from wazuh-indexer repo.
  • Workflow is invoked manually.

Functional requirements

  • The workflow receives the plugin name as a parameter
  • Indexer's build workflow can opt out from building plugins (TEST variable is promoted to the workflow as build_plugins boolean parameter, defaults to true.

Plan

  • Generate workflow to build plugins
  • Edit wazuh-indexer's build.yml to invoke the plugin's workflow
  • Edit the assemble.sh file to install the plugins
@AlexRuiz7
Copy link
Member Author

The workflow run for the wazuh-indexer failed and proved that the current design won't work unless we heavily interlace both workflows. Using a new approach. I'm aiming at building and publishing the plugins to the Maven local repository, so they can be installed later on in the build process.

This means the logic to build plugins will be part of the wazuh-indexer's build workflow. We will keep the build.yml workflow in the plugins repository as CI.

https://github.com/wazuh/wazuh-indexer/actions/runs/10419780534/job/28858529578

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
level/task Task issue type/enhancement Enhancement issue
Projects
Status: Done
2 participants