Aligning the JS build and caching with the main build (#31846)
Closes #31845 Signed-off-by: Alexander Schwartz <aschwart@redhat.com>
This commit is contained in:
parent
d17a48f8f8
commit
653f67768e
2 changed files with 10 additions and 25 deletions
13
.github/actions/pnpm-setup/action.yml
vendored
13
.github/actions/pnpm-setup/action.yml
vendored
|
@ -7,11 +7,6 @@ inputs:
|
||||||
required: false
|
required: false
|
||||||
default: "20"
|
default: "20"
|
||||||
|
|
||||||
working-directory:
|
|
||||||
description: The working directory where the `pnpm-lock.yaml` file is located.
|
|
||||||
required: false
|
|
||||||
default: ""
|
|
||||||
|
|
||||||
runs:
|
runs:
|
||||||
using: composite
|
using: composite
|
||||||
steps:
|
steps:
|
||||||
|
@ -38,11 +33,13 @@ runs:
|
||||||
path: |
|
path: |
|
||||||
~/.cache/Cypress
|
~/.cache/Cypress
|
||||||
${{ steps.pnpm-cache.outputs.store-path }}
|
${{ steps.pnpm-cache.outputs.store-path }}
|
||||||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('${{ inputs.working-directory }}/pnpm-lock.yaml') }}
|
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-pnpm-store-
|
${{ runner.os }}-pnpm-store-
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
working-directory: ${{ inputs.working-directory }}
|
|
||||||
shell: bash
|
shell: bash
|
||||||
run: pnpm install --prefer-offline --frozen-lockfile
|
# Run the store prune after the installation to avoid having caches which grow over time
|
||||||
|
run: |
|
||||||
|
pnpm install --prefer-offline --frozen-lockfile
|
||||||
|
pnpm store prune
|
||||||
|
|
22
.github/workflows/js-ci.yml
vendored
22
.github/workflows/js-ci.yml
vendored
|
@ -43,17 +43,11 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Setup Java
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
|
||||||
distribution: temurin
|
|
||||||
java-version: 21
|
|
||||||
check-latest: true
|
|
||||||
cache: maven
|
|
||||||
|
|
||||||
- name: Build Keycloak
|
- name: Build Keycloak
|
||||||
|
uses: ./.github/actions/build-keycloak
|
||||||
|
|
||||||
|
- name: Prepare archive for upload
|
||||||
run: |
|
run: |
|
||||||
./mvnw clean install --errors -DskipTests -DskipTestsuite -DskipExamples -Pdistribution
|
|
||||||
mv ./quarkus/dist/target/keycloak-999.0.0-SNAPSHOT.tar.gz ./keycloak-999.0.0-SNAPSHOT.tar.gz
|
mv ./quarkus/dist/target/keycloak-999.0.0-SNAPSHOT.tar.gz ./keycloak-999.0.0-SNAPSHOT.tar.gz
|
||||||
|
|
||||||
- name: Upload Keycloak dist
|
- name: Upload Keycloak dist
|
||||||
|
@ -164,10 +158,7 @@ jobs:
|
||||||
name: keycloak
|
name: keycloak
|
||||||
|
|
||||||
- name: Setup Java
|
- name: Setup Java
|
||||||
uses: actions/setup-java@v4
|
uses: ./.github/actions/java-setup
|
||||||
with:
|
|
||||||
distribution: temurin
|
|
||||||
java-version: 21
|
|
||||||
|
|
||||||
- name: Start Keycloak server
|
- name: Start Keycloak server
|
||||||
run: |
|
run: |
|
||||||
|
@ -258,10 +249,7 @@ jobs:
|
||||||
name: keycloak
|
name: keycloak
|
||||||
|
|
||||||
- name: Setup Java
|
- name: Setup Java
|
||||||
uses: actions/setup-java@v4
|
uses: ./.github/actions/java-setup
|
||||||
with:
|
|
||||||
distribution: temurin
|
|
||||||
java-version: 21
|
|
||||||
|
|
||||||
- name: Start Keycloak server
|
- name: Start Keycloak server
|
||||||
run: |
|
run: |
|
||||||
|
|
Loading…
Reference in a new issue