Skip to content

Commit

Permalink
fix: upgrade the version of GHA
Browse files Browse the repository at this point in the history
cherry-pick: e14778f
  • Loading branch information
Desvelao committed Dec 13, 2024
1 parent cce0616 commit 67588f6
Show file tree
Hide file tree
Showing 15 changed files with 46 additions and 35 deletions.
9 changes: 5 additions & 4 deletions .github/actions/run-cypress-tests/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ runs:
using: "composite"
steps:
- name: Set up JDK
uses: actions/setup-java@v1
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 11

- name: Set env
Expand All @@ -41,7 +42,7 @@ runs:
download-location: ${{ env.PLUGIN_NAME }}

- name: Run Opensearch with A Single Plugin
uses: derek-ho/start-opensearch@v2
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: "file:$(pwd)/opensearch-security.zip"
Expand All @@ -51,7 +52,7 @@ runs:

# OSD bootstrap
- name: Run Dashboard with Security Dashboards Plugin
uses: derek-ho/setup-opensearch-dashboards@v1
uses: derek-ho/setup-opensearch-dashboards@v3
with:
plugin_name: security-dashboards-plugin
opensearch_dashboards_yml: ${{ inputs.dashboards_config_file }}
Expand Down Expand Up @@ -104,7 +105,7 @@ runs:
shell: bash

- name: Run Cypress Tests with retry
uses: Wandalen/wretry.action@v3.3.0
uses: Wandalen/wretry.action@v3
with:
attempt_limit: 5
attempt_delay: 2000
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/auto-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,18 @@ jobs:
steps:
- name: GitHub App token
id: github_app_token
uses: tibdex/github-app-token@v1.5.0
uses: tibdex/github-app-token@v2.1.0
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
installation_id: 22958780
# https://github.com/tibdex/github-app-token/releases/tag/v2.0.0
# https://github.com/tibdex/github-app-token/compare/v1.5.0...v2.1.0#diff-1243c5424efaaa19bd8e813c5e6f6da46316e63761421b3e5f5c8ced9a36e6b6R11-R30
installation_retrieval_mode: id
installation_retrieval_payload: 22958780
- name: Get tag
id: tag
uses: dawidd6/action-get-tag@v1
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- uses: ncipollo/release-action@v1
with:
github_token: ${{ steps.github_app_token.outputs.token }}
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/backport.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,13 @@ jobs:
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
installation_id: 22958780
# https://github.com/tibdex/github-app-token/releases/tag/v2.0.0
# https://github.com/tibdex/github-app-token/compare/v1.5.0...v2.1.0#diff-1243c5424efaaa19bd8e813c5e6f6da46316e63761421b3e5f5c8ced9a36e6b6R11-R30
installation_retrieval_mode: id
installation_retrieval_payload: 22958780

- name: Backport
uses: VachaShah/backport@v2.2.0
uses: VachaShah/backport@v2
with:
github_token: ${{ steps.github_app_token.outputs.token }}
head_template: backport/backport-<%= number %>-to-<%= base %>
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cypress-test-multiauth-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

# Add SAML Configuration
- name: Injecting SAML Configuration for Linux
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

# Configure the Dashboard for multi datasources disabled (default)
- name: Create OpenSearch Dashboards Config
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set env
run: |
Expand Down Expand Up @@ -67,7 +67,7 @@ jobs:
download-location: ${{env.PLUGIN_NAME}}

- name: Run Opensearch with A Single Plugin
uses: derek-ho/start-opensearch@v4
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: "file:$(pwd)/opensearch-security.zip"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cypress-test-oidc-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

# Download and Check Keycloak Version
- name: Download and Check Keyloak Version on Linux
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cypress-test-saml-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

# Add SAML Configuration
- name: Create SAML Configuration for Linux
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/cypress-test-tenancy-disabled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,13 @@ jobs:

steps:
- name: Set up JDK
uses: actions/setup-java@v1
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 11

- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set env
run: |
Expand All @@ -47,7 +48,7 @@ jobs:
download-location: ${{ env.PLUGIN_NAME }}

- name: Run Opensearch with security
uses: derek-ho/start-opensearch@v2
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: 'file:$(pwd)/${{ env.PLUGIN_NAME }}.zip'
Expand All @@ -70,7 +71,7 @@ jobs:
EOT
- name: Run Dashboard with Security Dashboards Plugin
uses: derek-ho/setup-opensearch-dashboards@v1
uses: derek-ho/setup-opensearch-dashboards@v3
with:
plugin_name: security-dashboards-plugin
app_reference: ${{ vars.WZD_REF }}
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/cypress-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,13 @@ jobs:

steps:
- name: Set up JDK
uses: actions/setup-java@v1
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 11

- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set env
run: |
Expand All @@ -47,7 +48,7 @@ jobs:
download-location: ${{ env.PLUGIN_NAME }}

- name: Run Opensearch with security
uses: derek-ho/start-opensearch@v2
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: 'file:$(pwd)/${{ env.PLUGIN_NAME }}.zip'
Expand All @@ -72,7 +73,7 @@ jobs:
EOT
- name: Run Dashboard with Security Dashboards Plugin
uses: derek-ho/setup-opensearch-dashboards@v1
uses: derek-ho/setup-opensearch-dashboards@v3
with:
plugin_name: security-dashboards-plugin
app_reference: ${{ vars.WZD_REF }}
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/dev-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Step 01 - Download the plugin's source code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: wazuh/wazuh-security-dashboards-plugin
ref: ${{ inputs.reference }}
Expand Down Expand Up @@ -75,18 +75,19 @@ jobs:
yarn config set registry https://registry.yarnpkg.com;
cd /home/node/kbn/plugins/wazuh-security-plugin && yarn && ${{ inputs.command }};
'
- name: Get the plugin version and and format reference name
- name: Get the plugin version and format reference name
run: |
echo "githubReference=$(echo ${{ inputs.reference }} | sed 's/\//-/g')" >> $GITHUB_ENV
echo "version=$(jq -r '.wazuh.version' $(pwd)/wazuh-security-plugin/package.json)" >> $GITHUB_ENV
echo "revision=$(jq -r '.wazuh.revision' $(pwd)/wazuh-security-plugin/package.json)" >> $GITHUB_ENV
- name: Step 04 - Upload artifact to GitHub
if: ${{ inputs.artifact_name && inputs.artifact_path }}
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.artifact_name }}_${{ env.version }}-${{ env.revision }}_${{ env.githubReference }}.zip
path: ${{ inputs.artifact_path }}
overwrite: true

- name: Step 05 - Upload coverage results to GitHub
if: ${{ inputs.notify_jest_coverage_summary && github.event_name == 'pull_request' }}
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/integration-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@ jobs:

steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up JDK
uses: actions/setup-java@v1
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 11

- name: Set env
Expand Down Expand Up @@ -69,7 +70,7 @@ jobs:
plugin-version: ${{ env.PLUGIN_VERSION }}

- name: Run Opensearch with A Single Plugin Remote Cluster
uses: derek-ho/start-opensearch@v4
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: "file:$(pwd)/opensearch-security-${{ env.OPENSEARCH_VERSION }}.zip"
Expand All @@ -84,7 +85,7 @@ jobs:
shell: bash

- name: Run Opensearch with security
uses: derek-ho/start-opensearch@v2
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: 'file:$(pwd)/${{ env.PLUGIN_NAME }}.zip'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
# run: git config --system core.longpaths true

- name: Checkout Branch
uses: actions/checkout@v2
uses: actions/checkout@v4

- id: install-dashboards
uses: derek-ho/setup-opensearch-dashboards@v3
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/verify-binary-installation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set env
run: |
Expand All @@ -39,7 +39,7 @@ jobs:
download-location: ${{ env.PLUGIN_NAME }}

- name: Run Opensearch with security
uses: derek-ho/start-opensearch@v2
uses: derek-ho/start-opensearch@v6
with:
opensearch-version: ${{ env.OPENSEARCH_VERSION }}
plugins: "file:$(pwd)/${{ env.PLUGIN_NAME }}.zip"
Expand Down Expand Up @@ -67,7 +67,7 @@ jobs:
- name: Run Dashboard with Security Dashboards Plugin
id: setup-dashboards
uses: derek-ho/setup-opensearch-dashboards@v2
uses: derek-ho/setup-opensearch-dashboards@v3
with:
plugin_name: security-dashboards-plugin
built_plugin_name: security-dashboards
Expand Down

0 comments on commit 67588f6

Please sign in to comment.