mirror of
https://github.com/icereed/paperless-gpt.git
synced 2025-03-14 05:38:01 -05:00
Add GitHub Actions workflow for caching npm dependencies and building and pushing Docker images
This commit is contained in:
parent
8e06dff432
commit
fbb0d3aced
1 changed files with 10 additions and 0 deletions
10
.github/workflows/docker-build-and-push.yml
vendored
10
.github/workflows/docker-build-and-push.yml
vendored
|
@ -33,6 +33,14 @@ jobs:
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
|
|
||||||
|
- name: Cache npm dependencies
|
||||||
|
uses: actions/cache@v3
|
||||||
|
with:
|
||||||
|
path: ~/.npm
|
||||||
|
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-node-
|
||||||
|
|
||||||
- name: Install frontend dependencies
|
- name: Install frontend dependencies
|
||||||
run: npm install
|
run: npm install
|
||||||
working-directory: web-app
|
working-directory: web-app
|
||||||
|
@ -67,6 +75,8 @@ jobs:
|
||||||
context: .
|
context: .
|
||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
cache-from: type=gha
|
||||||
|
cache-to: type=gha,mode=max
|
||||||
tags: |
|
tags: |
|
||||||
icereed/paperless-gpt:unreleased
|
icereed/paperless-gpt:unreleased
|
||||||
${{ github.ref == 'refs/heads/main' && 'icereed/paperless-gpt:unreleased' }}
|
${{ github.ref == 'refs/heads/main' && 'icereed/paperless-gpt:unreleased' }}
|
||||||
|
|
Loading…
Reference in a new issue