Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(ci): rebuild sharp for arm64 and cache node_modules #1434

Merged
merged 3 commits into from
Aug 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions .github/workflows/dockerize-server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ on:
branches:
- main
paths:
- "server/**"
- ".github/workflows/dockerize-server.yml"
- "!**/*.md"
- "!server/package-lock.json"
- 'server/**'
- '.github/workflows/dockerize-server.yml'
- '!**/*.md'
- '!server/package-lock.json'

concurrency:
group: dockerize-server-${{ github.ref }}
Expand All @@ -24,14 +24,22 @@ jobs:
with:
fetch-depth: 0

- name: Cache node modules
id: cache-node-modules
uses: actions/cache@v3
with:
path: server/node_modules
key: ${{ runner.os }}-node-${{ hashFiles('server/package-lock.json') }}

- name: Use Node
uses: actions/setup-node@v3
with:
node-version: 18.x

- name: Install Package
working-directory: server
run: npm cache clean --force && npm install
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm ci && npm rebuild --arch=arm64 sharp

- name: Build server
working-directory: server
Expand Down
140 changes: 115 additions & 25 deletions server/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.