From cf5f80dd61309c06c0a1fd279c8b9f41fc7f6410 Mon Sep 17 00:00:00 2001 From: Jeroen Benckhuijsen <jeroen.benckhuijsen@gmail.com> Date: Tue, 28 Jan 2025 14:29:02 +0100 Subject: [PATCH 1/2] Initial version, try run npm install from docker-maven-plugin --- .github/workflows/build.yml | 4 --- firebase-devservices/deployment/pom.xml | 35 +++++++++++++++++++++++++ 2 files changed, 35 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 241c398b..df888974 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -30,10 +30,6 @@ jobs: cache: 'npm' cache-dependency-path: firebase-devservices/deployment/src/test/functions/package-lock.json - - uses: bahmutov/npm-install@v1 - with: - working-directory: firebase-devservices/deployment/src/test/functions - - name: Cache local Maven repository uses: actions/cache@v2 with: diff --git a/firebase-devservices/deployment/pom.xml b/firebase-devservices/deployment/pom.xml index f8f5b649..01433df8 100644 --- a/firebase-devservices/deployment/pom.xml +++ b/firebase-devservices/deployment/pom.xml @@ -152,6 +152,41 @@ quarkus-google-cloud-common-grpc and Quarkus includes the netty library --> </execution> </executions> </plugin> + <plugin> + <groupId>io.fabric8</groupId> + <artifactId>docker-maven-plugin</artifactId> + <version>0.45.1</version> + <executions> + <execution> + <id>npm-install-before-testing</id> + <goals> + <goal>stop</goal> + <goal>start</goal> + </goals> + <phase>process-test-resources</phase> + <configuration> + <images> + <image> + <!-- Node version must match version in package.json --> + <name>node:20</name> + <run> + <cmd>npm install</cmd> + <workingDir>/tmp/node</workingDir> + <volumes> + <bind> + <volume>src/test/functions:/tmp/node</volume> + </bind> + </volumes> + <wait> + <exit>0</exit> + </wait> + </run> + </image> + </images> + </configuration> + </execution> + </executions> + </plugin> </plugins> </build> From 2b64440d3c7e6792af5922cf2fc89f30bcff904c Mon Sep 17 00:00:00 2001 From: Jeroen Benckhuijsen <jeroen.benckhuijsen@gmail.com> Date: Tue, 28 Jan 2025 15:26:45 +0100 Subject: [PATCH 2/2] Remove node build step (replaced with maven plugin) --- .github/workflows/quarkus-snapshot.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/quarkus-snapshot.yaml b/.github/workflows/quarkus-snapshot.yaml index aaa90c2e..a3f4671d 100644 --- a/.github/workflows/quarkus-snapshot.yaml +++ b/.github/workflows/quarkus-snapshot.yaml @@ -42,10 +42,6 @@ jobs: repository: ${{ env.ECOSYSTEM_CI_REPO }} path: ecosystem-ci - - uses: actions/setup-node@v4 - with: - node-version: 20 - - uses: bahmutov/npm-install@v1 with: working-directory: current-repo/firebase-devservices/deployment/src/test/functions