feat/45 :: 크리에이터 권한 요청 API 구현 #205
This file contains hidden or 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: F-Lab SonarCloud Code Analyze | |
| on: | |
| pull_request: | |
| types: [opened, synchronize, reopened] | |
| workflow_dispatch: | |
| env: | |
| CACHED_DEPENDENCIES_PATHS: '**/node_modules' | |
| jobs: | |
| CodeAnalyze: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up JDK 21 | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: temurin | |
| java-version: '21' | |
| - name: Compile Java classes | |
| run: ./services/auth/gradlew --no-daemon classes | |
| - name: Set SonarCloud Project Key | |
| run: | | |
| REPO_NAME=$(echo $GITHUB_REPOSITORY | cut -d '/' -f 2) | |
| ORG_NAME=$(echo $GITHUB_REPOSITORY | cut -d '/' -f 1) | |
| SONAR_PROJECT_KEY="${ORG_NAME}_${REPO_NAME}" | |
| SONAR_JAVA_BINARIES=$(find . -type d -path "*/build/classes/java/main" | sed 's|^\./||' | paste -sd "," -) | |
| echo "SONAR_PROJECT_KEY=$SONAR_PROJECT_KEY" >> $GITHUB_ENV | |
| echo "SONAR_JAVA_BINARIES=$SONAR_JAVA_BINARIES" >> $GITHUB_ENV | |
| - name: Analyze with SonarCloud | |
| uses: SonarSource/sonarcloud-github-action@master | |
| id: analyze-sonarcloud | |
| continue-on-error: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.SECRET_GITHUB_BOT }} | |
| SONAR_TOKEN: ${{ secrets.SECRET_SONARQUBE }} | |
| with: | |
| args: | |
| -Dsonar.projectKey=${{ env.SONAR_PROJECT_KEY }} | |
| -Dsonar.organization=f-lab-edu-1 | |
| -Dsonar.java.binaries=${{ env.SONAR_JAVA_BINARIES }} | |
| -Dsonar.cpd.exclusions=**/services/*/src/main/java/**/adapter/in/web/exception/handler/GlobalExceptionHandler.java,**/services/*/src/main/java/**/adapter/out/persistence/entity/BaseEntity.java | |