Build and Run Wazuh Dashboard App from github on Windows

1,314 views
Skip to first unread message

Rajneesh Bajaj

unread,
Jun 29, 2023, 8:11:47 AM6/29/23
to Wazuh mailing list
Hi,

I want to customize the Wazuh_Dashboard_App, so I decided follow OpenSearch Kibana Plugin development path.

I checked out the source code


Build Dashboard
1. Bootstrap : yarn osd bootstrap
2. Start OpenSearch Server : yarn opensearch snapshot
3. Start Dashboard server : yarn start

I was able to open the dashboard. So brought down the server and dashboard to build Wazuh plugin.

Build Wazuh Plugin
1.  Copied plugin directory from Kibana-Plugin to Plugin directory of Dashboard.
2.  yarn update and yarn build

Ran the OpenSearch Server and then the Dashboard server.

I could see the Wazuh plugin but it complained about API not being available.
I failed to see that Wazuh Manager is required and couldn't find an easy way to build it on my windows machine.

I think I may have take a complicated path for development. Is there a documentation around it ?

Any suggestions?

Thanks



Mauricio Aguilar

unread,
Jun 29, 2023, 9:39:52 AM6/29/23
to Wazuh mailing list
Hi Rajneesh,

Let me check this problem and come back with some answer.

In the meantime, what version of windows are you using?

Best regards,
The Wazuh Team

Rajneesh Bajaj

unread,
Jun 29, 2023, 9:53:31 AM6/29/23
to Wazuh mailing list
I am using windows 11

Mauricio Aguilar

unread,
Jun 30, 2023, 1:38:48 PM6/30/23
to Wazuh mailing list
Hi again,

Checking with the team, I have some points here:

- The plugin complains that the Wazuh Api is not available.
- Wazuh API is part of the Wazuh Server: (RESTful API service) https://documentation.wazuh.com/current/getting-started/components/index.html
- So, it is necessary to have it installed.
 
There are a couple of commands that you can check:
  • Check if the process is running:
    command 1: wazuh-control status command 2: ps -ef | grep apid
In the output of this command you might find the problem.

- Regarding to how to install Wazuh on Windows, there are several alternatives: https://documentation.wazuh.com/4.4/deployment-options/index.html
You could use the OVA file over VirtualBox to deploy Wazuh, or docker. 

Best Regards,
The Wazuh Team.

Rajneesh Bajaj

unread,
Jul 3, 2023, 1:25:30 PM7/3/23
to Wazuh mailing list
Hi Wazuh Team,

I have used VirtualBox to install the image on Windows and I am able to access the Wazuh Dashboard from the installed version.
Now, I want to make some changes in Wazuh-Kibana-app and deploy it. Would you be able to suggest?

Warm Regards
Rajneesh

Alejandro Ruiz Becerra

unread,
Jul 5, 2023, 10:22:15 AM7/5/23
to Wazuh mailing list
Hello Rajneesh

I'm Alex, team leader of the Wazuh's frontend team

The plugin needs at least one Wazuh API to work. For development, we use Imposter, a mock server which allows us to mock the Wazuh API, so it's not need to install and deploy all the Wazuh services that the API needs, including the API itself.
We do host our development environments in the docker folder of our repos. In this case, wazuh-kibana-app/docker

In there, there are several README files that you can read. Long story short, you need:

- To up a Docker environment based on OpenSearch, as Wazuh dashboard is a fork of it --> docker/osd-dev

There is a dev.sh file in there, run it with the required parameters: bash dev.sh 2.6.0 2.6.0 <absolute_path_to_wazuh_kibana/plugins/main> up

Enter the dashboard container and start the app with yarn start --no-base-path

If the plugin shows the version mismatch error, edit docker/imposter/api-info/api-info.json file with the correct version, and restart the imposter container

Note that this will use a vanilla version of OpenSearch Dashboards, not Wazuh Dashboard. The app has its own docker environments too. We do develop and test separately, but we'll include development environments using Wazuh Dashboard instead of OpenSearch Dashboards in the future. Feel free to contribute to the project if you wish to create it.

I hope this helps. If you have more questions or need more assistance, please open and issue in wazuh-kibana-app, and we'll be glad to help

Regards
Alex

Pragya Dechalwal

unread,
Dec 19, 2023, 7:14:17 AM12/19/23
to Wazuh | Mailing List
Hi,
I want to build wazuh dashboard and wazuh-dashboard plugin from source .
I am using wazuh dashboard version 4.6.0 https://github.com/wazuh/wazuh-dashboard/tree/4.6.0
For wazuh-dashboard plugin I am using branch with tag v4.6.0-2.8.0 https://github.com/wazuh/wazuh-dashboard-plugins/tree/v4.6.0-2.8.0
But I am facing error for  conflicting versions of certain dependencies across different package.json files.
Screenshot from 2023-12-19 12-44-36.png

Steps I have followed till now
git checkout 4.6.0
cd plugins
git checkout v4.6.0-2.8.0
cd ../
in wazuh dashboard directory I then ran yarn osd bootstrap and then I got the above issue.
Can someone explain me how can I build  wazuh dashboard and wazuh-dashboard plugin from source  and which versions of both are compatible with each other.
Thanks in advance
STL - Sterlite Technologies Limited Disclaimer:
The content of this message may be legally privileged and confidential and are for the use of the intended recipient(s) only. It should not be read, copied and used by anyone other than the intended recipient(s). If you have received this message in error, please immediately notify the sender, preserve its confidentiality and delete it. Before opening any attachments please check them for viruses and defects. No employee or agent is authorised to conclude any binding agreement on behalf of Sterlite Technologies Limited with another party by email without express written confirmation by authorised personVisit us at www.stl.tech
 Please consider environment before printing this email !

Registered office: E 1, MIDC Industrial Area, Waluj, Aurangabad, Maharashtra – 431 136 CIN – L31300MH2000PLC269261

Pablo Ariel Gonzalez

unread,
May 14, 2024, 5:02:34 PM5/14/24
to Wazuh | Mailing List
Hi  Rajneesh,

I know it has been some time since your inquiry. But if it would be of use to you we have continued to analyze this issue and propose alternatives in the following Slack community thread.

Thanks,
Reply all
Reply to author
Forward
0 new messages