Skip to content

Commit

Permalink
update ci + node 18
Browse files Browse the repository at this point in the history
  • Loading branch information
arch1995 committed May 31, 2023
1 parent 9f4721d commit 8bae22d
Show file tree
Hide file tree
Showing 7 changed files with 78 additions and 189 deletions.
44 changes: 10 additions & 34 deletions .github/workflows/alphas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,35 +11,23 @@ jobs:
name: Test release
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]

runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
cache: 'npm'

- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Pre-build setup
run: npm run pre-build
Expand All @@ -57,36 +45,24 @@ jobs:
name: Build & deploy alpha*.tor.us
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

needs: test

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
cache: 'npm'

- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Run build
run: npm run build:alpha-branches
Expand Down
46 changes: 11 additions & 35 deletions .github/workflows/binance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,37 +11,25 @@ jobs:
name: Test release
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]

runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ssh-key: ${{ secrets.ALPHA_SSH_KEY }}

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
cache: 'npm'

- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Pre-build setup
run: npm run pre-build
Expand All @@ -59,45 +47,33 @@ jobs:
name: Build & deploy binance.tor.us
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

needs: test

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
ssh-key: ${{ secrets.ALPHA_SSH_KEY }}

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
cache: 'npm'

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
uses: aws-actions/configure-aws-credentials@v2
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-1

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Run build
run: |
Expand Down
22 changes: 5 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,35 +15,23 @@ jobs:
name: ci
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]

runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
cache: 'npm'

- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm instal

- name: Pre-build setup
run: npm run pre-build
Expand Down
49 changes: 18 additions & 31 deletions .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,35 +11,23 @@ jobs:
name: Test release
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]

runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

- name: Get npm cache directory
id: npm-cache
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: Node dependency cache
uses: actions/cache@v2
with:
path: ${{ steps.npm-cache.outputs.dir }}
key: ${{ matrix.os }}-node-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ matrix.os }}-node-
cache: 'npm'

- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Pre-build setup
run: npm run pre-build
Expand All @@ -57,18 +45,18 @@ jobs:
name: Build & deploy testing.tor.us
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

needs: test

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

Expand All @@ -86,7 +74,7 @@ jobs:
${{ matrix.os }}-node-
- name: Install dependencies
run: npm install --legacy-peer-deps
run: npm install

- name: Run build
run: npm run build:testing
Expand Down Expand Up @@ -117,18 +105,18 @@ jobs:
name: Build & deploy lrc.tor.us
strategy:
matrix:
node: ['16.x']
node: ['18.x']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

needs: test

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}

Expand Down Expand Up @@ -165,10 +153,9 @@ jobs:

# Invalidate Cloudfront (this action)
- name: invalidate
uses: chetan/invalidate-cloudfront-action@master
env:
DISTRIBUTION: ${{ secrets.DISTRIBUTION_LRC_TOR_US }}
PATHS: '/*'
AWS_REGION: 'us-east-1'
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
uses: chaitanyapotti/cloudfront-update-distribution@v2
with:
cloudfront-distribution-id: ${{ secrets.DISTRIBUTION_LRC_TOR_US }}
cloudfront-invalidation-path: '/*'
cloudfront-invalidation-required: true
cloudfront-wait-for-service-update: false
Loading

0 comments on commit 8bae22d

Please sign in to comment.