Skip to content

Commit 2bd0b86

Browse files
committed
Update setup node for linux
Signed-off-by: Rupal Mahajan <maharup@amazon.com>
1 parent 4fc7ae4 commit 2bd0b86

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

.github/workflows/dashboards-reports-test-and-build-workflow.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,15 @@ jobs:
2323
ref: ${{ env.OPENSEARCH_VERSION }}
2424
path: dashboards-reports/OpenSearch-Dashboards
2525

26-
- name: Setup Node
27-
uses: actions/setup-node@v1
28-
with:
29-
node-version: "10.24.1"
26+
- name: Get node version
27+
id: versions_step
28+
run:
29+
echo "::set-output name=node_version::$(node -p "(require('./OpenSearch-Dashboards/package.json').engines.node).match(/[.0-9]+/)[0]")"
30+
- name: Setup Node
31+
uses: actions/setup-node@v1
32+
with:
33+
node-version: ${{ steps.versions_step.outputs.node_version }}
34+
registry-url: 'https://registry.npmjs.org'
3035

3136
- name: Move Dashboards Reports to Plugins Dir
3237
run: mv dashboards-reports OpenSearch-Dashboards/plugins/${{ env.PLUGIN_NAME }}

0 commit comments

Comments
 (0)