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

Merge 4.10.1 into 4.10.2 #1583

Merged
merged 37 commits into from
Oct 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
eb4efb3
Bump 4.9.1 revision
c-bordon Sep 27, 2024
e292957
Merge pull request #1548 from wazuh/enhancement/1418-support-new-stag…
davidcr01 Sep 27, 2024
62ae93e
Updated Wazuh images to -rc2 version
c-bordon Sep 27, 2024
be0ac01
Merge pull request #1549 from wazuh/enhancement/1547-update-docker-im…
davidcr01 Sep 27, 2024
0ec38df
Revert Wazuh images to -rc2 version
c-bordon Sep 27, 2024
af023a9
Merge pull request #1550 from wazuh/enhancement/1547-revert-docker-im…
teddytpc1 Sep 27, 2024
027b260
Update Procedure_push_docker_images.yml
YisDav Sep 30, 2024
8bafe12
Change the dev default value to true for the workflow_dispatch
YisDav Oct 1, 2024
cc20665
Merge pull request #1551 from wazuh/enhancement/1864-improve-push-doc…
teddytpc1 Oct 1, 2024
92d0582
Revert create_user.py script deletion
Enaraque Oct 3, 2024
d237faa
Merge pull request #1555 from wazuh/bug/1554-wazuh-server-container-r…
c-bordon Oct 3, 2024
884151b
Bumped revision for 4.9.1-RC3
davidcr01 Oct 4, 2024
97e4dde
Merge pull request #1559 from wazuh/enhancement/1558-bump-revision
davidcr01 Oct 4, 2024
4177d10
Changed image tag for 4.9.1-rc3
davidcr01 Oct 4, 2024
bd7aedc
Merge pull request #1560 from wazuh/enhancement/1558-change-image-tag
davidcr01 Oct 4, 2024
868c371
Reverted image tag for 4.9.1-rc3
davidcr01 Oct 4, 2024
61b3f5f
Merge pull request #1561 from wazuh/enhancement/1558-revert-image-tag
davidcr01 Oct 4, 2024
8695a08
Resolving merge conflicts
vcerenu Oct 10, 2024
06a797d
Merge pull request #1568 from wazuh/merge-4.9.1-into-4.10.0
teddytpc1 Oct 10, 2024
1aa1499
Fix typos
vcerenu Oct 10, 2024
f61af29
Add changelog
vcerenu Oct 10, 2024
6074636
Merge pull request #1569 from wazuh/bug/1564-fix-typos-entrypoint
teddytpc1 Oct 10, 2024
dbb7766
Bump revision
YisDav Oct 10, 2024
50769ef
Merge pull request #1571 from wazuh/enhancement/1570-add-support-for-…
c-bordon Oct 10, 2024
db4133d
Update docker-compose versions
YisDav Oct 10, 2024
424846a
Merge pull request #1572 from wazuh/enhancement/1570-docker-compose-v…
teddytpc1 Oct 10, 2024
5795fa1
Revert image tag to 4.10.0
YisDav Oct 10, 2024
b1f0a1f
Merge pull request #1573 from wazuh/enhancement/1570-revert-image-tag
teddytpc1 Oct 10, 2024
276c8a2
Bump revision
vcerenu Oct 15, 2024
564e2b3
change image taf for rc4
vcerenu Oct 15, 2024
5bbaceb
Revert image tag for rc4
vcerenu Oct 15, 2024
691694a
Resolve conflicts
vcerenu Oct 17, 2024
f4e7d19
Merge pull request #1581 from wazuh/merge-4.9.1-into-4-10-0
teddytpc1 Oct 17, 2024
42977e3
Resolve conflicts
vcerenu Oct 17, 2024
7ca14b9
Resolve conflicts
vcerenu Oct 17, 2024
ea0e679
Merge pull request #1582 from wazuh/merge-4.10.0-into-4.10.1
teddytpc1 Oct 17, 2024
a5c3138
Resolve conflicts
vcerenu Oct 17, 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
99 changes: 76 additions & 23 deletions .github/workflows/Procedure_push_docker_images.yml
Original file line number Diff line number Diff line change
@@ -1,33 +1,84 @@
run-name: Launch Push Docker Images - Executed by @${{ github.actor }}
run-name: Launch Push Docker Images - ${{ inputs.id }}
name: Push Docker Images

on:
workflow_dispatch:
inputs:
IMAGE_TAG:
image_tag:
description: 'Docker image tag'
default: '4.10.2'
required: true
DOCKER_REFERENCE:
docker_reference:
description: 'wazuh-docker reference'
default: 'v4.10.2'
required: true
PRODUCTS:
description: 'Comma-separated list of the image names to build and push'
default: 'wazuh-manager,wazuh-dashboard,wazuh-indexer'
required: true
FILEBEAT_MODULE_VERSION:
filebeat_module_version:
description: 'Filebeat module version'
default: '0.4'
required: true
REVISION:
revision:
description: 'Package revision'
default: '1'
required: true
PUSH_IMAGES:
push_images:
description: 'Push images'
type: boolean
default: true
required: true
id:
description: "ID used to identify the workflow uniquely."
type: string
required: false
dev:
description: "Add tag suffix '-dev' to the image tag ?"
type: boolean
default: true
required: false
workflow_call:
inputs:
image_tag:
description: 'Docker image tag'
default: '4.10.0'
required: true
type: string
docker_reference:
description: 'wazuh-docker reference'
default: 'v4.10.0'
required: false
type: string
products:
description: 'Comma-separated list of the image names to build and push'
default: 'wazuh-manager,wazuh-dashboard,wazuh-indexer'
required: true
type: string
filebeat_module_version:
description: 'Filebeat module version'
default: '0.4'
required: true
type: string
revision:
description: 'Package revision'
default: '1'
required: true
type: string
push_images:
description: 'Push images'
type: boolean
default: true
required: true
id:
description: "ID used to identify the workflow uniquely."
type: string
required: false
dev:
description: "Add tag suffix '-dev' to the image tag ?"
type: boolean
default: false
required: false

jobs:
build-and-push:
Expand All @@ -44,23 +95,25 @@ jobs:
echo "---------------------------------------------"
echo "Inputs provided:"
echo "---------------------------------------------"
echo "* IMAGE_TAG: ${{ inputs.IMAGE_TAG }}"
echo "* DOCKER_REFERENCE: ${{ inputs.DOCKER_REFERENCE }}"
echo "* PRODUCTS: ${{ inputs.PRODUCTS }}"
echo "* FILEBEAT_MODULE_VERSION: ${{ inputs.FILEBEAT_MODULE_VERSION }}"
echo "* REVISION: ${{ inputs.REVISION }}"
echo "* PUSH_IMAGES: ${{ inputs.PUSH_IMAGES }}"
echo "* id: ${{ inputs.id }}"
echo "* image_tag: ${{ inputs.image_tag }}"
echo "* docker_reference: ${{ inputs.docker_reference }}"
echo "* products: ${{ inputs.products }}"
echo "* filebeat_module_version: ${{ inputs.filebeat_module_version }}"
echo "* revision: ${{ inputs.revision }}"
echo "* push_images: ${{ inputs.push_images }}"
echo "* dev: ${{ inputs.dev }}"
echo "---------------------------------------------"

- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ inputs.DOCKER_REFERENCE }}
ref: ${{ inputs.docker_reference }}

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: wazuh
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}

- name: Install Docker Compose
Expand All @@ -71,10 +124,9 @@ jobs:

- name: Build Wazuh images
run: |
IMAGE_TAG=${{ inputs.IMAGE_TAG }}
FILEBEAT_MODULE_VERSION=${{ inputs.FILEBEAT_MODULE_VERSION }}
REVISION=${{ inputs.REVISION }}
PUSH_IMAGES=${{ inputs.PUSH_IMAGES }}
IMAGE_TAG=${{ inputs.image_tag }}
FILEBEAT_MODULE_VERSION=${{ inputs.filebeat_module_version }}
REVISION=${{ inputs.revision }}

if [[ "$IMAGE_TAG" == *"-"* ]]; then
IFS='-' read -r -a tokens <<< "$IMAGE_TAG"
Expand All @@ -89,8 +141,9 @@ jobs:
./build-docker-images/build-images.sh -v $IMAGE_TAG -r $REVISION -f $FILEBEAT_MODULE_VERSION
fi

# Save .env file (generated by build-images.sh) contents to $GITHUB_ENV
ENV_FILE_PATH=".env"
# Save .env file contents to $GITHUB_ENV

if [ -f $ENV_FILE_PATH ]; then
while IFS= read -r line || [ -n "$line" ]; do
echo "$line" >> $GITHUB_ENV
Expand All @@ -100,15 +153,15 @@ jobs:
exit 1
fi


- name: Tag and Push Wazuh images
if: ${{ inputs.PUSH_IMAGES }}
if: ${{ inputs.push_images }}
run: |
IMAGE_TAG=${{ inputs.IMAGE_TAG }}
IMAGE_NAMES=${{ inputs.PRODUCTS }}
IMAGE_TAG="${{ inputs.image_tag }}$( [ "${{ inputs.dev }}" == "true" ] && echo '-dev' || true )"
IMAGE_NAMES=${{ inputs.products }}
IFS=',' read -r -a images <<< "$IMAGE_NAMES"
for image in "${images[@]}"; do
echo "Tagging and pushing wazuh/$image:${WAZUH_VERSION} to wazuh/$image:$IMAGE_TAG"
docker tag wazuh/$image:${WAZUH_VERSION} wazuh/$image:$IMAGE_TAG
echo "Pushing wazuh/$image:$IMAGE_TAG ..."
docker push wazuh/$image:$IMAGE_TAG
done
69 changes: 61 additions & 8 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,79 @@
# Change Log
All notable changes to this project will be documented in this file.

## Wazuh Docker v4.10.2
## [4.10.2]

### Added

- Update Wazuh to version [4.10.2](https://github.com/wazuh/wazuh/blob/v4.10.2/CHANGELOG.md#v4101)
- none

### Changed

- None

### Fixed

- None

### Deleted

- None

## [4.10.1]

## Wazuh Docker v4.10.1
### Added

- Update Wazuh to version [4.10.1](https://github.com/wazuh/wazuh/blob/v4.10.1/CHANGELOG.md#v4101)
- none

### Changed

- None

### Fixed

- None

### Deleted

- None

## [4.10.0]

## Wazuh Docker v4.10.0
### Added

- Migrate the push docker images procedure to GitHub Actions ([#5651](https://github.com/wazuh/wazuh-qa/issues/5651))
- Update Wazuh to version [4.10.0](https://github.com/wazuh/wazuh/blob/v4.10.0/CHANGELOG.md#v4100)

## Wazuh Docker v4.9.1
### Changed

- None

### Fixed

- None

### Deleted

- None

## [4.9.1]

### Added

- Update Wazuh to version [4.9.1](https://github.com/wazuh/wazuh/blob/v4.9.1/CHANGELOG.md#v491)
- None

### Changed

- None


### Fixed

- Fix typos into Wazuh manager entrypoint ([#1569](https://github.com/wazuh/wazuh-docker/pull/1569))

### Deleted

- None


## Wazuh Docker v4.9.0
### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ mount_permanent_data() {
print "Installing ${permanent_dir}"
exec_cmd "cp -a ${data_tmp}. ${permanent_dir}"
else
print "The path ${permanent_dir} is empty, skiped"
print "The path ${permanent_dir} is empty, skipped"
fi
fi
done
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
set -e

if [ "$INDEXER_URL" != "" ]; then
>&2 echo "Customize Elasticsearch ouput IP"
>&2 echo "Customize Elasticsearch output IP"
sed -i "s|hosts:.*|hosts: ['$INDEXER_URL']|g" /etc/filebeat/filebeat.yml
fi

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ EOF
if /var/ossec/framework/python/bin/python3 /var/ossec/framework/scripts/create_user.py; then
# remove json if exit code is 0
rm /var/ossec/api/configuration/admin.json
rm /var/ossec/framework/scripts/create_user.py
else
echored "There was an error configuring the API user"
# terminate container to avoid unpredictable behavior
Expand Down
Loading