Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
d3d2ae7
Bump version to 5.0.0
davidcr01 Feb 13, 2024
b47361e
Merge pull request #1207 from wazuh/bump-5.0.0
davidcr01 Feb 13, 2024
799dadc
Merge pull request #1243 from wazuh/merge-4.9.0-into-master
teddytpc1 Mar 1, 2024
4f0da7a
Merge branch '4.9.0' into merge-4.9.0-into-master
davidcr01 Mar 4, 2024
e8d2463
Merge pull request #1251 from wazuh/merge-4.9.0-into-master
teddytpc1 Mar 4, 2024
935aee6
Fixed references to 4.8 in `master`
davidcr01 Mar 19, 2024
9918f95
Merge pull request #1269 from wazuh/bug/1193-review-version-reference…
teddytpc1 Mar 20, 2024
dc13ef3
Merge branch '4.9.0' into merge-4.9.0-into-master
davidcr01 Apr 1, 2024
f685bfa
Merge branch 'master' into merge-4.9.0-into-master
davidcr01 Apr 1, 2024
c95eb42
Merge pull request #1285 from wazuh/merge-4.9.0-into-master
davidcr01 Apr 1, 2024
f4ccd4b
Removed commented lines 87 to 91
CarlosALgit Apr 9, 2024
fa025c6
Merge pull request #1292 from wazuh/enhancement/#1291-remove-commente…
teddytpc1 Apr 9, 2024
10f278c
add environment variables for configure wazuh indexer and dashboard f…
vcerenu Apr 23, 2024
7ec98fe
correct environment settings in services
vcerenu Apr 24, 2024
3d7c673
Merge pull request #1327 from wazuh/merge-4.9.0-into-master
teddytpc1 Apr 30, 2024
937b5fa
Merge pull request #1312 from wazuh/461-conf-files-environment
teddytpc1 May 17, 2024
37918b4
Merge branch 'master' of github.com:wazuh/wazuh-docker into 4.9.0
vcerenu May 31, 2024
4ba7cba
Merge pull request #1375 from wazuh/1371-merge-4.9.0-into-master
teddytpc1 May 31, 2024
fc1ece7
Add the build of Wazuh cert tool image to build image process
vcerenu Jun 7, 2024
1f32d2a
Modify yaml script name generator
vcerenu Jun 7, 2024
6d63bef
Modify yaml script name generator
vcerenu Jun 7, 2024
450a59a
Change the name dir to Wazuh cert tool Dockerfile
vcerenu Jun 10, 2024
aed1004
Change the generator script in multi node deployment
vcerenu Jun 10, 2024
1e6f93b
Correct the name of the certificate generator script
vcerenu Jun 11, 2024
fda4a17
Add save and load process for Wazuh Cert Tool image
vcerenu Jun 11, 2024
cf3eb61
Add save and load process for Wazuh Cert Tool image
vcerenu Jun 11, 2024
36e7160
Add save and load process for Wazuh Cert Tool image
vcerenu Jun 11, 2024
7eb5d08
Merge pull request #1385 from wazuh/enhancement/1256-wazuh-cert-tool
teddytpc1 Jun 12, 2024
e1d70c3
Merge pull request #1392 from wazuh/merge-4.9.0-into-master
teddytpc1 Jun 12, 2024
33a0508
Add .whitesource configuration file
mend-bolt-for-github[bot] Jul 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .env
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
WAZUH_VERSION=4.9.0
WAZUH_IMAGE_VERSION=4.9.0
WAZUH_VERSION=5.0.0
WAZUH_IMAGE_VERSION=5.0.0
WAZUH_TAG_REVISION=1
FILEBEAT_TEMPLATE_BRANCH=4.9.0
FILEBEAT_TEMPLATE_BRANCH=5.0.0
WAZUH_FILEBEAT_MODULE=wazuh-filebeat-0.4.tar.gz
WAZUH_UI_REVISION=1
2 changes: 1 addition & 1 deletion .github/.goss.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ package:
wazuh-manager:
installed: true
versions:
- 4.9.0-1
- 5.0.0-1
port:
tcp:1514:
listening: true
Expand Down
29 changes: 25 additions & 4 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
docker save wazuh/wazuh-manager:${{env.WAZUH_IMAGE_VERSION}} -o /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-manager.tar
docker save wazuh/wazuh-indexer:${{env.WAZUH_IMAGE_VERSION}} -o /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-indexer.tar
docker save wazuh/wazuh-dashboard:${{env.WAZUH_IMAGE_VERSION}} -o /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-dashboard.tar
docker save wazuh/wazuh-cert-tool:${{env.WAZUH_IMAGE_VERSION}} -o /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-cert-tool.tar

- name: Temporarily save Wazuh manager Docker image
uses: actions/upload-artifact@v3
Expand All @@ -44,6 +45,13 @@ jobs:
path: /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-dashboard.tar
retention-days: 1

- name: Temporarily save Wazuh Cert Tool Docker image
uses: actions/upload-artifact@v3
with:
name: docker-artifact-cert-tool
path: /home/runner/work/wazuh-docker/wazuh-docker/docker-images/wazuh-cert-tool.tar
retention-days: 1

- name: Install Goss
uses: e1himself/goss-installation-action@v1.0.3
with:
Expand Down Expand Up @@ -81,15 +89,22 @@ jobs:
with:
name: docker-artifact-dashboard

- name: Retrieve saved Wazuh Cert Tool Docker image
uses: actions/download-artifact@v3
with:
name: docker-artifact-cert-tool

- name: Docker load
run: |
docker load --input ./wazuh-indexer.tar
docker load --input ./wazuh-dashboard.tar
docker load --input ./wazuh-manager.tar
docker load --input ./wazuh-cert-tool.tar
rm -rf wazuh-manager.tar wazuh-indexer.tar wazuh-dashboard.tar wazuh-cert-tool.tar


- name: Create single node certficates
run: docker-compose -f single-node/generate-indexer-certs.yml run --rm generator
run: docker-compose -f single-node/generate-certs.yml run --rm generator

- name: Start single node stack
run: docker-compose -f single-node/docker-compose.yml up -d
Expand Down Expand Up @@ -212,15 +227,21 @@ jobs:
with:
name: docker-artifact-indexer

- name: Retrieve saved Wazuh Cert Tool Docker image
uses: actions/download-artifact@v3
with:
name: docker-artifact-cert-tool

- name: Docker load
run: |
docker load --input ./wazuh-manager.tar
docker load --input ./wazuh-indexer.tar
docker load --input ./wazuh-dashboard.tar
rm -rf wazuh-manager.tar wazuh-indexer.tar wazuh-dashboard.tar
docker load --input ./wazuh-manager.tar
docker load --input ./wazuh-cert-tool.tar
rm -rf wazuh-manager.tar wazuh-indexer.tar wazuh-dashboard.tar wazuh-cert-tool.tar

- name: Create multi node certficates
run: docker-compose -f multi-node/generate-indexer-certs.yml run --rm generator
run: docker-compose -f multi-node/generate-certs.yml run --rm generator

- name: Start multi node stack
run: docker-compose -f multi-node/docker-compose.yml up -d
Expand Down
14 changes: 14 additions & 0 deletions .whitesource
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"scanSettings": {
"baseBranches": []
},
"checkRunSettings": {
"vulnerableCheckRunConclusionLevel": "failure",
"displayMode": "diff",
"useMendCheckNames": true
},
"issueSettings": {
"minSeverityLevel": "LOW",
"issueType": "DEPENDENCY"
}
}
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# Change Log
All notable changes to this project will be documented in this file.

## Wazuh Docker v5.0.0
### Added

- Update Wazuh to version [5.0.0](https://github.com/wazuh/wazuh/blob/v5.0.0/CHANGELOG.md#v500)

## Wazuh Docker v4.9.0
### Added

Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ WAZUH_MONITORING_REPLICAS=0 ##
│   │   └── wazuh_indexer_ssl_certs
│   │   └── certs.yml
│   ├── docker-compose.yml
│   ├── generate-indexer-certs.yml
│   ├── generate-certs.yml
│   ├── Migration-to-Wazuh-4.3.md
│   └── volume-migrator.sh
├── README.md
Expand All @@ -181,7 +181,7 @@ WAZUH_MONITORING_REPLICAS=0 ##
│   │   ├── wazuh.manager-key.pem
│   │   └── wazuh.manager.pem
│   ├── docker-compose.yml
│   ├── generate-indexer-certs.yml
│   ├── generate-certs.yml
│   └── README.md
└── VERSION

Expand All @@ -196,6 +196,7 @@ WAZUH_MONITORING_REPLICAS=0 ##

| Wazuh version | ODFE | XPACK |
|---------------|---------|--------|
| v5.0.0 | | |
| v4.9.0 | | |
| v4.8.2 | | |
| v4.8.1 | | |
Expand Down
4 changes: 2 additions & 2 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
WAZUH-DOCKER_VERSION="4.9.0"
REVISION="40900"
WAZUH-DOCKER_VERSION="5.0.0"
REVISION="50000"
4 changes: 2 additions & 2 deletions build-docker-images/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ This script initializes the environment variables needed to build each of the im
The script allows you to build images from other versions of Wazuh, to do this you must use the -v or --version argument:

```
$ build-docker-images/build-images.sh -v 4.9.0
$ build-docker-images/build-images.sh -v 5.0.0
```

To get all the available script options use the -h or --help option:
Expand All @@ -26,7 +26,7 @@ Usage: build-docker-images/build-images.sh [OPTIONS]
-d, --dev <ref> [Optional] Set the development stage you want to build, example rc1 or beta1, not used by default.
-f, --filebeat-module <ref> [Optional] Set Filebeat module version. By default 0.4.
-r, --revision <rev> [Optional] Package revision. By default 1
-v, --version <ver> [Optional] Set the Wazuh version should be builded. By default, 4.9.0.
-v, --version <ver> [Optional] Set the Wazuh version should be builded. By default, 5.0.0.
-h, --help Show this help.

```
5 changes: 3 additions & 2 deletions build-docker-images/build-images.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
WAZUH_IMAGE_VERSION=4.9.0
WAZUH_IMAGE_VERSION=5.0.0
WAZUH_VERSION=$(echo $WAZUH_IMAGE_VERSION | sed -e 's/\.//g')
WAZUH_TAG_REVISION=1
WAZUH_CURRENT_VERSION=$(curl --silent https://api.github.com/repos/wazuh/wazuh/releases/latest | grep '["]tag_name["]:' | sed -E 's/.*\"([^\"]+)\".*/\1/' | cut -c 2- | sed -e 's/\.//g')
Expand All @@ -12,7 +12,7 @@ IMAGE_VERSION=${WAZUH_IMAGE_VERSION}
# License (version 2) as published by the FSF - Free Software
# Foundation.

WAZUH_IMAGE_VERSION="4.9.0"
WAZUH_IMAGE_VERSION="5.0.0"
WAZUH_TAG_REVISION="1"
WAZUH_DEV_STAGE=""
FILEBEAT_MODULE_VERSION="0.4"
Expand Down Expand Up @@ -71,6 +71,7 @@ build() {
echo WAZUH_UI_REVISION=$WAZUH_UI_REVISION >> .env

docker-compose -f build-docker-images/build-images.yml --env-file .env build --no-cache
docker build -t wazuh/wazuh-cert-tool:$WAZUH_IMAGE_VERSION build-docker-images/cert-tool-image/

return 0
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Wazuh Docker Copyright (C) 2017, Wazuh Inc. (License GPLv2)
FROM ubuntu:focal
FROM amazonlinux:2023

RUN apt-get update && apt-get install openssl curl -y
RUN yum install curl-minimal openssl -y &&\
yum clean all

WORKDIR /

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
## Variables
CERT_TOOL=wazuh-certs-tool.sh
PASSWORD_TOOL=wazuh-passwords-tool.sh
PACKAGES_URL=https://packages.wazuh.com/4.9/
PACKAGES_DEV_URL=https://packages-dev.wazuh.com/4.9/
PACKAGES_URL=https://packages.wazuh.com/5.0/
PACKAGES_DEV_URL=https://packages-dev.wazuh.com/5.0/

## Check if the cert tool exists in S3 buckets
CERT_TOOL_PACKAGES=$(curl --silent -I $PACKAGES_URL$CERT_TOOL | grep -E "^HTTP" | awk '{print $2}')
Expand Down
14 changes: 13 additions & 1 deletion build-docker-images/wazuh-dashboard/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,15 @@ RUN chmod 775 /install_wazuh_app.sh
RUN bash /install_wazuh_app.sh

# Copy and set permissions to config files
COPY config/opensearch_dashboards.yml $INSTALL_DIR/config/
RUN cp $INSTALL_DIR/etc/opensearch_dashboards.yml $INSTALL_DIR/config/opensearch_dashboards.yml
COPY config/wazuh.yml $INSTALL_DIR/data/wazuh/config/
RUN chmod 664 $INSTALL_DIR/config/opensearch_dashboards.yml

# Create and set permissions to data directories
RUN mkdir -p $INSTALL_DIR/data/wazuh && chmod -R 775 $INSTALL_DIR/data/wazuh
RUN mkdir -p $INSTALL_DIR/data/wazuh/config && chmod -R 775 $INSTALL_DIR/data/wazuh/config
RUN mkdir -p $INSTALL_DIR/data/wazuh/logs && chmod -R 775 $INSTALL_DIR/data/wazuh/logs
RUN mkdir /wazuh-config-mount && chmod -R 775 /wazuh-config-mount

################################################################################
# Build stage 1 (the current Wazuh dashboard image):
Expand Down Expand Up @@ -108,6 +109,15 @@ COPY --from=builder --chown=1000:1000 $INSTALL_DIR $INSTALL_DIR
RUN mkdir -p /usr/share/wazuh-dashboard/plugins/wazuh/public/assets/custom
RUN chown 1000:1000 /usr/share/wazuh-dashboard/plugins/wazuh/public/assets/custom

# Set $JAVA_HOME
RUN echo "export JAVA_HOME=$INSTALL_DIR/jdk" >> /etc/profile.d/java_home.sh && \
echo "export PATH=\$PATH:\$JAVA_HOME/bin" >> /etc/profile.d/java_home.sh
ENV JAVA_HOME=$INSTALL_DIR/jdk
ENV PATH=$PATH:$JAVA_HOME/bin:$INSTALL_DIR/bin

# Add k-NN lib directory to library loading path variable
ENV LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$INSTALL_DIR/plugins/opensearch-knn/lib"

# Set workdir and user
WORKDIR $INSTALL_DIR
USER wazuh-dashboard
Expand All @@ -116,3 +126,5 @@ USER wazuh-dashboard
EXPOSE 443

ENTRYPOINT [ "/entrypoint.sh" ]

CMD ["opensearch-dashboards"]
8 changes: 4 additions & 4 deletions build-docker-images/wazuh-dashboard/config/config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ export CONFIG_DIR=${INSTALLATION_DIR}/config

## Variables
CERT_TOOL=wazuh-certs-tool.sh
PACKAGES_URL=https://packages.wazuh.com/4.9/
PACKAGES_DEV_URL=https://packages-dev.wazuh.com/4.9/
PACKAGES_URL=https://packages.wazuh.com/5.0/
PACKAGES_DEV_URL=https://packages-dev.wazuh.com/5.0/

## Check if the cert tool exists in S3 buckets
CERT_TOOL_PACKAGES=$(curl --silent -I $PACKAGES_URL$CERT_TOOL | grep -E "^HTTP" | awk '{print $2}')
Expand All @@ -34,8 +34,8 @@ chmod 755 $CERT_TOOL && bash /$CERT_TOOL -A
mkdir -p ${CONFIG_DIR}/certs

# Copy Wazuh dashboard certs to install config dir
cp /wazuh-certificates/demo.dashboard.pem ${CONFIG_DIR}/certs/dashboard.pem
cp /wazuh-certificates/demo.dashboard-key.pem ${CONFIG_DIR}/certs/dashboard-key.pem
cp /wazuh-certificates/dashboard.pem ${CONFIG_DIR}/certs/dashboard.pem
cp /wazuh-certificates/dashboard-key.pem ${CONFIG_DIR}/certs/dashboard-key.pem
cp /wazuh-certificates/root-ca.pem ${CONFIG_DIR}/certs/root-ca.pem

chmod -R 500 ${CONFIG_DIR}/certs
Expand Down
4 changes: 2 additions & 2 deletions build-docker-images/wazuh-dashboard/config/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
nodes:
# Wazuh dashboard server nodes
dashboard:
- name: demo.dashboard
ip: demo.dashboard
- name: dashboard
ip: wazuh.dashboard
Loading