SK-1633 Fix failures in workflow #10
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: Endor Labs Scan Java Project | |
| on: | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| inputs: | |
| java_version: | |
| description: "The version of Java to be used for build" | |
| default: "8.0.422" | |
| required: true | |
| jobs: | |
| build-and-scan: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-java@v1 | |
| with: | |
| java-version: "1.8" | |
| # distribution: zulu | |
| # java-version: ${{ github.event.inputs.java_version }} | |
| server-id: ossrh | |
| server-username: ${{ secrets.OSSRH_USERNAME }} | |
| server-password: ${{ secrets.OSSRH_PASSWORD }} | |
| gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import | |
| gpg-passphrase: ${{ secrets.MAVEN_GPG_PASSPHRASE }} # env variable for GPG private key passphrase | |
| - name: Create env | |
| id: create-env | |
| run: | | |
| touch .env | |
| echo SKYFLOW_CREDENTIALS=${{ secrets.SKYFLOW_CREDENTIALS }} >> .env | |
| echo TEST_EXPIRED_TOKEN=${{ secrets.TEST_EXPIRED_TOKEN }} >> .env | |
| echo TEST_REUSABLE_TOKEN=${{ secrets.TEST_REUSABLE_TOKEN }} >> .env | |
| - name: create-json | |
| id: create-json | |
| uses: jsdaniell/create-json@1.1.2 | |
| with: | |
| name: "credentials.json" | |
| json: ${{ secrets.TEST_CREDENTIALS_FILE_STRING }} | |
| - name: Compile Package | |
| run: mvn clean install | |
| env: | |
| SERVER_USERNAME: ${{ secrets.server-username }} | |
| SERVER_PASSWORD: ${{ secrets.server-password }} | |
| GPG_PASSPHRASE: ${{ secrets.gpg-passphrase }} | |
| # - name: Endor Labs SCA Scan | |
| # uses: endorlabs/github-action@main | |
| # with: | |
| # namespace: "skyflow" | |
| # api: "https://api.endorlabs.com" | |
| # pr: false | |
| # enable_github_action_token: true | |
| # scan_dependencies: true | |
| # additional_args: "--as-default-branch --call-graph-languages=java" |