Skip to content

Commit

Permalink
Fix JVM environment workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Md Soharab Ansari <[email protected]>
  • Loading branch information
soharab-ic committed Sep 4, 2024
1 parent 3a0349e commit 467238c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
24 changes: 10 additions & 14 deletions .github/workflows/environment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ name: Environments build and test
on:
pull_request:
branches: [master]
env:
FISSION_CLI_VERSION: 1.20.3

jobs:
# Job to run change detection
check:
Expand Down Expand Up @@ -135,20 +132,19 @@ jobs:
kubectl cluster-info --context kind-kind
kind get kubeconfig >$HOME/.kube/config
kubectl get nodes
- name: Install Fission CLI
- name: Base Setup
run: |
curl -Lo fission https://github.com/fission/fission/releases/download/${{ env.FISSION_CLI_VERSION }}/fission-${{ env.FISSION_CLI_VERSION }}-linux-amd64 \
&& chmod +x fission && sudo mv fission /usr/local/bin/
make verify-kind-cluster
make install-fission-cli
make install-skaffold
make create-crds
- name: jvm
uses: hiberbee/[email protected]
with:
skaffold-version: '2.13.1'
command: run
profile: jvm
tag: latest
- name: jvm-tests
run: |
kind load docker-image jvm-env && ./test_utils/run_test.sh jvm/tests/test_java_env.sh
SKAFFOLD_PROFILE=jvm make skaffold-run
make jvm-test-images
make router-port-forward
- name: jvm-tests
run: ./test_utils/run_test.sh jvm/tests/test_java_env.sh
nodejs:
runs-on: ubuntu-latest
needs: check
Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@ go-test-images:
@kind load docker-image go-env
@kind load docker-image go-builder

jvm-test-images:
@kind load docker-image jvm-env
@kind load docker-image jvm-builder

nodejs-test-images:
@kind load docker-image node-env
@kind load docker-image node-builder
Expand Down
2 changes: 1 addition & 1 deletion jvm/tests/test_java_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ cd jvm/examples/java

log "Creating the jar from application"
#Using Docker to build Jar so that maven & other Java dependencies are not needed on CI server
docker run -it --rm -v "$(pwd)":/usr/src/mymaven -w /usr/src/mymaven maven:3.5-jdk-8 mvn clean package -q
docker run -it --rm -v "$(pwd)":/usr/src/mymaven -w /usr/src/mymaven maven:3.9.9-eclipse-temurin-22-alpine mvn clean package -q

log "Creating environment for Java"
fission env create --name $env --image $JVM_RUNTIME_IMAGE --version 2 --keeparchive=true
Expand Down

0 comments on commit 467238c

Please sign in to comment.