Change deploy process

This commit is contained in:
vcerenu
2025-05-14 15:44:12 -03:00
parent 16c6984a8a
commit 4bb6cc9a29
6 changed files with 87 additions and 73 deletions

View File

@@ -25,6 +25,4 @@
- [CEnvironment Variabless](ref/configuration/environment-variables.md)
- [Configuration files](ref/configuration/configuration-files.md)
- [Upgrade](ref/upgrade.md)
- [Back Up and Restore](ref/backup-restore.md)
- [Security](ref/security.md)
- [Glossary](ref/glossary.md)

View File

@@ -1 +0,0 @@
# Back Up and Restore

View File

@@ -1,32 +1,34 @@
# Wazuh Docker deployment
# Wazuh Docker Deployment
## Deploy Wazuh Docker in multi node configuration
## Deploying Wazuh Docker in a Multi-Node Configuration
This deployment is defined in the `multi-node/docker-compose.yml` file with two Wazuh manager containers, three Wazuh indexer containers, and one Wazuh dashboard container. It can be deployed by following these steps:
This deployment utilizes the `multi-node/docker-compose.yml` file, which defines a cluster setup with two Wazuh manager containers, three Wazuh indexer containers, and one Wazuh dashboard container. Follow these steps to deploy this configuration:
1) Enter the multi-node directory of the repository:
```
$ cd multi-node
```
2) Increase max_map_count on your host (Linux). This command must be run with root permissions:
```
$ sysctl -w vm.max_map_count=262144
```
3) Run the certificate creation script:
```
$ docker-compose -f generate-indexer-certs.yml run --rm generator
```
4) Start the environment with docker-compose:
1. Navigate to the `multi-node` directory within your repository:
```bash
cd multi-node
```
- In the foregroud:
```
$ docker-compose up
```
2. Increase `vm.max_map_count` on each Docker host that will run a Wazuh Indexer container (Linux). This setting is crucial for Wazuh Indexer to operate correctly. This command requires root permissions:
```bash
sudo sysctl -w vm.max_map_count=262144
```
**Note:** This change is temporary and will revert upon reboot. To make it permanent on each relevant host, you'll need to edit the `/etc/sysctl.conf` file, add `vm.max_map_count=262144`, and then apply the change with `sudo sysctl -p`.
- In the background:
```
$ docker-compose up -d
```
3. Run the script to generate the necessary certificates for the Wazuh Stack. This ensures secure communication between the nodes:
```bash
docker-compose -f generate-indexer-certs.yml run --rm generator
```
4. Start the Wazuh environment using `docker-compose`:
The environment takes about 1 minute to get up (depending on your Docker host) for the first time since Wazuh Indexer must be started for the first time and the indexes and index patterns must be generated.
* To run in the foreground (logs will be displayed in your current terminal; press `Ctrl+C` to stop):
```bash
docker-compose up
```
* To run in the background (detached mode, allowing the containers to run independently of your terminal):
```bash
docker-compose up -d
```
Please allow some time for the environment to initialize, especially on the first run. A multi-node setup can take a few minutes (depending on your host resources and network) as the Wazuh Indexer cluster forms, and the necessary indexes and index patterns are generated.

View File

@@ -1,31 +1,35 @@
# Wazuh Docker deployment
# Wazuh Docker Deployment
## Deploy Wazuh Docker in single node configuration
## Deploying Wazuh Docker in a Single-Node Configuration
This deployment is defined in the `single-node/docker-compose.yml` file with one Wazuh manager containers, one Wazuh indexer containers, and one Wazuh dashboard container. It can be deployed by following these steps:
This deployment uses the `single-node/docker-compose.yml` file, which defines a setup with one Wazuh manager container, one Wazuh indexer container, and one Wazuh dashboard container. Follow these steps to deploy it:
1) Enter the single-node directory of the repository:
```
$ cd single-node
```
2) Increase max_map_count on your host (Linux). This command must be run with root permissions:
```
$ sysctl -w vm.max_map_count=262144
```
3) Run the certificate creation script:
```
$ docker-compose -f generate-indexer-certs.yml run --rm generator
```
4) Start the environment with docker-compose:
1. Navigate to the `single-node` directory within your repository:
```bash
cd single-node
```
- In the foregroud:
```
$ docker-compose up
```
- In the background:
```
$ docker-compose up -d
```
2. Increase `vm.max_map_count` on each Docker host that will run a Wazuh Indexer container (Linux). This setting is crucial for Wazuh Indexer to operate correctly. This command requires root permissions:
```bash
sudo sysctl -w vm.max_map_count=262144
```
**Note:** This change is temporary and will revert upon reboot. To make it permanent, you'll need to edit the `/etc/sysctl.conf` file and add `vm.max_map_count=262144`, then apply with `sudo sysctl -p`.
The environment takes about 1 minute to get up (depending on your Docker host) for the first time since Wazuh Indexer must be started for the first time and the indexes and index patterns must be generated.
3. Run the script to generate the necessary certificates for the Wazuh Stack. This ensures secure communication between the nodes:
```bash
docker-compose -f generate-indexer-certs.yml run --rm generator
```
4. Start the Wazuh environment using `docker-compose`:
* To run in the foreground (logs will be displayed in your current terminal; press `Ctrl+C` to stop):
```bash
docker-compose up
```
* To run in the background (detached mode, allowing the containers to run independently of your terminal):
```bash
docker-compose up -d
```
Please allow some time for the environment to initialize, especially on the first run. It can take approximately a minute or two (depending on your host's resources) as the Wazuh Indexer starts up and generates the necessary indexes and index patterns.

View File

@@ -1,24 +1,36 @@
# Wazuh Docker deployment
# Wazuh Docker Deployment
## Deploy Wazuh agent
## Deploying the Wazuh Agent
1) Enter the `wazuh-agent` directory of the repository.
```
$ cd wazuh-agent
```
2) Edit the `docker-compose.yml` file, changing the current value of the `WAZUH_MANAGER_SERVER` variable to the IP or URL of the Wazuh manager:
```
Follow these steps to deploy the Wazuh agent using Docker.
1. Navigate to the `wazuh-agent` directory within your repository:
```bash
cd wazuh-agent
```
2. Edit the `docker-compose.yml` file. You need to update the `WAZUH_MANAGER_SERVER` environment variable with the IP address or hostname of your Wazuh manager.
Locate the `environment` section for the agent service and update it as follows:
```yaml
# Inside your docker-compose.yml file
# services:
# wazuh-agent:
# ...
environment:
- WAZUH_MANAGER_SERVER=<WAZUH_MANAGER_IP>
```
3) Start the environment with docker-compose:
- WAZUH_MANAGER_SERVER=<YOUR_WAZUH_MANAGER_IP_OR_HOSTNAME>
# ...
```
**Note:** Replace `<YOUR_WAZUH_MANAGER_IP_OR_HOSTNAME>` with the actual IP address or hostname of your Wazuh manager.
- In the foregroud:
```
$ docker-compose up
```
3. Start the environment using `docker-compose`:
- In the background:
```
$ docker-compose up -d
```
* To run in the foreground (logs will be displayed in your current terminal, and you can stop it with `Ctrl+C`):
```bash
docker-compose up
```
* To run in the background (detached mode, allowing the container to run independently of your terminal):
```bash
docker-compose up -d
```

View File

@@ -1 +0,0 @@
# Security