Skip to content

Commit

Permalink
ci: use setup node action instead of container image
Browse files Browse the repository at this point in the history
  • Loading branch information
ali-hosseini-deriv committed Nov 6, 2023
1 parent eb57962 commit 48786af
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 12 deletions.
20 changes: 14 additions & 6 deletions .github/workflows/release_production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ on:
jobs:
build_and_test:
runs-on: ubuntu-latest
container:
image: node:12.22.7
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: 12.22
- name: Install dependencies
uses: "./.github/actions/npm_install"
- name: Build
Expand All @@ -29,12 +31,15 @@ jobs:
path: dist
publish_cloudflare_production:
runs-on: ubuntu-latest
container:
image: node:20.2.0

needs: [build_and_test]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Download Artifacts
uses: actions/[email protected]
with:
Expand All @@ -44,12 +49,15 @@ jobs:
notify_on_slack:
if: always()
runs-on: ubuntu-latest
container:
image: node:20.2.0

needs: [publish_cloudflare_production, build_and_test]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Conclusion
uses: technote-space/workflow-conclusion-action@v3
- uses: actions/[email protected]
Expand Down
12 changes: 8 additions & 4 deletions .github/workflows/release_staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ on:
jobs:
build_and_test:
runs-on: ubuntu-latest
container:
image: node:12.22.7
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: 12.22
- name: Install dependencies
uses: "./.github/actions/npm_install"
- name: Build
Expand All @@ -28,12 +30,14 @@ jobs:
path: dist
publish_cloudflare_production:
runs-on: ubuntu-latest
container:
image: node:20.2.0
needs: [build_and_test]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20.x
- uses: actions/[email protected]
with:
path: dist
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ on:
jobs:
build_and_test:
runs-on: ubuntu-latest
container:
image: node:12.22.7
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: 12.22
- name: Install dependencies
uses: "./.github/actions/npm_install"
- name: Build
Expand Down

0 comments on commit 48786af

Please sign in to comment.