Update maven.yml (#10) #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build, Test, and Analyze Spring Boot Application | |
on: | |
push: | |
branches: [main] | |
jobs: | |
build_test_and_analyze: | |
name: Build, Test and Analyze | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Cache Maven dependencies | |
uses: actions/cache@v2 | |
with: | |
path: ~/.m2 | |
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | |
restore-keys: ${{ runner.os }}-m2 | |
- name: Build project with Maven | |
run: mvn -B clean compile --file pom.xml | |
- name: Test project with Maven | |
run: mvn test | |
- name: SOOS DAST test | |
uses: soos-io/soos-dast-github-action@v2 | |
with: | |
client_id: i78cbw2bh | |
api_key: NTc1MDMzNjMtODU2Ni00MTE4LTkxODYtMTVlN2JkNWQwMjgy | |
project_name: "magazyn-server" | |
scan_mode: "baseline" | |
api_url: "https://api.soos.io/api/" | |
target_url: "http://localhost:8080" |