From 07b816f6b3b023accb7dc7094847b1cd3bf20bbd Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Wed, 29 May 2024 17:34:34 +0200 Subject: [PATCH 1/8] Added S3 URI output --- .github/workflows/build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b9ec941531217..a947bba38c43c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -185,6 +185,8 @@ jobs: src="artifacts/dist/${{ steps.package.outputs.name }}" dest="s3://packages-dev.internal.wazuh.com/development/wazuh/4.x/main/packages/" aws s3 cp "$src" "$dest" + s3uri="${dest}${{ steps.package.outputs.name }}" + echo "S3 URI: ${s3uri}" - name: Upload checksum to S3 if: ${{ inputs.upload && inputs.checksum }} @@ -192,3 +194,5 @@ jobs: src="artifacts/dist/${{ steps.package.outputs.name }}.sha512" dest="s3://packages-dev.internal.wazuh.com/development/wazuh/4.x/main/packages/" aws s3 cp "$src" "$dest" + s3uri="${dest}${{ steps.package.outputs.name }}.sha512" + echo "S3 sha512 URI: ${s3uri}" From 70c488891ce5653db4f2b0ae6fcaa0bce6a7ce73 Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Tue, 4 Jun 2024 18:51:06 +0200 Subject: [PATCH 2/8] Added ID input and S3 URI output --- .github/workflows/build.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a947bba38c43c..c08139654ab43 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Build packages (on demand) +name: Build packages (on demand) | ${{ inputs.id }} # This workflow runs when any of the following occur: # - Run manually @@ -30,6 +30,9 @@ on: description: "Checksum ?" type: boolean default: false + id: + type: string + required: false workflow_call: inputs: revision: @@ -56,6 +59,9 @@ on: description: "Checksum ?" type: boolean default: false + id: + type: string + required: false secrets: CI_INTERNAL_DEVELOPMENT_BUCKET_USER_ACCESS_KEY: required: true From ab9dfda10d2c59fea2b11e9bb8b1928c10215249 Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Tue, 4 Jun 2024 18:55:31 +0200 Subject: [PATCH 3/8] Improved workflow run name --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c08139654ab43..22eb4c1a7ecc3 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Build packages (on demand) | ${{ inputs.id }} +run-name: Build packages (on demand) ${{ inputs.distribution }} wazuh-indexer on ${{ inputs.architecture }} | ${{ inputs.id }} # This workflow runs when any of the following occur: # - Run manually From 6fb24072352fbd9e8ee308d8acd3db85cd098a89 Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Wed, 5 Jun 2024 15:07:15 +0200 Subject: [PATCH 4/8] Added name statement --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 22eb4c1a7ecc3..6f55fd5a7ae02 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,5 @@ run-name: Build packages (on demand) ${{ inputs.distribution }} wazuh-indexer on ${{ inputs.architecture }} | ${{ inputs.id }} +name: Build Wazuh indexer (on demand) # This workflow runs when any of the following occur: # - Run manually From 17787ad858a3a0d9d0e20617a1e32d44144a8081 Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Wed, 5 Jun 2024 15:41:42 +0200 Subject: [PATCH 5/8] Added name statement --- .github/workflows/build_single.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_single.yml b/.github/workflows/build_single.yml index 56be9cd9f1e90..8254924cf4a29 100644 --- a/.github/workflows/build_single.yml +++ b/.github/workflows/build_single.yml @@ -1,4 +1,5 @@ run-name: Build ${{ inputs.system }} wazuh-indexer on ${{ inputs.architecture }} | ${{ inputs.id }} +name: Build Wazuh indexer (single) # This workflow runs when any of the following occur: # - Run from another worklow of GH API From 278d5f55a18983deab656a5c3fd115ade60e818e Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Wed, 5 Jun 2024 19:49:10 +0200 Subject: [PATCH 6/8] Removed file --- .github/workflows/build_single.yml | 79 ------------------------------ 1 file changed, 79 deletions(-) delete mode 100644 .github/workflows/build_single.yml diff --git a/.github/workflows/build_single.yml b/.github/workflows/build_single.yml deleted file mode 100644 index 8254924cf4a29..0000000000000 --- a/.github/workflows/build_single.yml +++ /dev/null @@ -1,79 +0,0 @@ -run-name: Build ${{ inputs.system }} wazuh-indexer on ${{ inputs.architecture }} | ${{ inputs.id }} -name: Build Wazuh indexer (single) - -# This workflow runs when any of the following occur: -# - Run from another worklow of GH API -# - Run manually -on: - workflow_call: - inputs: - revision: - description: "Revision" - type: string - default: "0" - checksum: - description: "Checksum ?" - type: boolean - default: false - is_stage: - description: "Is stage ?" - type: boolean - default: false - system: - description: "Package OS" - type: string - default: deb - architecture: - description: "Package architecture" - type: string - default: amd64 - id: - description: "ID used to identify the workflow uniquely." - type: string - required: false - - workflow_dispatch: - inputs: - revision: - description: "Revision" - type: string - default: "0" - checksum: - description: "Checksum ?" - type: boolean - default: false - is_stage: - description: "Is stage ?" - type: boolean - default: false - system: - description: "Package OS" - type: choice - options: - - rpm - - deb - default: deb - architecture: - description: "Package architecture" - type: choice - options: - - amd64 - - x86_64 - default: amd64 - id: - description: "ID used to identify the workflow uniquely." - type: string - required: false - -jobs: - call-build-workflow: - uses: ./.github/workflows/build.yml - with: - revision: ${{ inputs.revision }} - checksum: ${{ inputs.checksum }} - is_stage: ${{ inputs.is_stage }} - distribution: '[ "${{ inputs.system }}" ]' - upload: true - # Architecture is always 'x64', which is the default value in ./build.yml - # It is an input just for convenience and standardisation. - secrets: inherit From 84b296704e37f1320a1d7ec90ac6ab6bddd5a742 Mon Sep 17 00:00:00 2001 From: Raul Del Pozo Moreno Date: Thu, 6 Jun 2024 17:39:46 +0200 Subject: [PATCH 7/8] Added ID input description --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6f55fd5a7ae02..4d3297d51108c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,6 +32,7 @@ on: type: boolean default: false id: + description: "ID used to identify the workflow uniquely." type: string required: false workflow_call: From 34fa3ddedb3d0702fd93b643709927d07f164ab7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lex=20Ruiz?= Date: Fri, 7 Jun 2024 12:18:45 +0200 Subject: [PATCH 8/8] Update build.yml --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4d3297d51108c..9afe6c40034fe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,5 +1,5 @@ -run-name: Build packages (on demand) ${{ inputs.distribution }} wazuh-indexer on ${{ inputs.architecture }} | ${{ inputs.id }} -name: Build Wazuh indexer (on demand) +run-name: Build ${{ inputs.distribution }} Wazuh Indexer on ${{ inputs.architecture }} | ${{ inputs.id }} +name: Build packages (on demand) # This workflow runs when any of the following occur: # - Run manually