Skip to content

Commit

Permalink
Apply reference name change
Browse files Browse the repository at this point in the history
  • Loading branch information
Tostti committed Nov 29, 2024
1 parent 8f898da commit 2a09ae9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/dev-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,16 +118,17 @@ jobs:
cd /home/node/kbn/plugins/${{ matrix.plugins.container_path }} && yarn && ${{ inputs.command }};
'
- name: Get the plugin version
- name: Get the plugin version and and format reference name
run: |
echo "githubReference=$(echo ${{ inputs.reference }} | sed 's/\//-/g')" >> $GITHUB_ENV
echo "version=$(jq -r '.version' $(pwd)/wazuh/plugins/main/package.json)" >> $GITHUB_ENV
echo "revision=$(jq -r '.revision' $(pwd)/wazuh/plugins/main/package.json)" >> $GITHUB_ENV
- name: Step 04 - Upload artifact to GitHub
if: ${{ inputs.artifact_name && inputs.artifact_path }}
uses: actions/upload-artifact@v3
with:
name: ${{ inputs.artifact_name }}_${{ env.version }}-${{ env.revision }}_${{ inputs.reference }}.zip
name: ${{ inputs.artifact_name }}_${{ env.version }}-${{ env.revision }}_${{ env.githubReference }}.zip
path: ${{ matrix.plugins.path }}/${{ inputs.artifact_path }}
if-no-files-found: 'error'

Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/manual-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,9 @@ jobs:
ref: ${{ inputs.reference }}
path: wazuh

- name: Step 02 - Get version and revision
- name: Step 02 - Set variables
run: |
echo "githubReference=$(echo ${{ inputs.reference }} | sed 's/\//-/g')" >> $GITHUB_ENV
echo "currentDir=$(pwd -P)" >> $GITHUB_ENV
echo "version=$(jq -r '.version' $(pwd)/wazuh/plugins/main/package.json)" >> $GITHUB_ENV
echo "revision=$(jq -r '.revision' $(pwd)/wazuh/plugins/main/package.json)" >> $GITHUB_ENV
Expand All @@ -55,8 +56,8 @@ jobs:
- name: Step 03 - Download the plugin's source code
uses: actions/download-artifact@v3
with:
name: wazuh-dashboard-plugins_${{ env.version }}-${{ env.revision }}_${{ inputs.reference }}.zip
path: ${{ env.currentDir }}/wazuh/scripts/test-packages/wazuh-dashboard-plugins_${{ env.version }}-${{ env.revision }}_${{ inputs.reference }}.zip
name: wazuh-dashboard-plugins_${{ env.version }}-${{ env.revision }}_${{ env.githubReference }}.zip
path: ${{ env.currentDir }}/wazuh/scripts/test-packages/wazuh-dashboard-plugins_${{ env.version }}-${{ env.revision }}_${{ env.githubReference }}.zip

- name: Step 04 - Build the Docker image
run: |
Expand Down

0 comments on commit 2a09ae9

Please sign in to comment.