revert the changes for ci #237
Workflow file for this run
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: Build and Deploy Java Project | |
| on: | |
| push: | |
| branches: [ '**' ] | |
| tags: [ '*' ] | |
| pull_request: | |
| branches: [ '**' ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 # Ubuntu Jammy equivalent | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: '17' | |
| distribution: 'adopt' # AdoptOpenJDK's new name | |
| cache: 'maven' | |
| gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '16.20.2' | |
| cache: 'npm' | |
| - name: Clone and build parent project | |
| run: | | |
| git clone --depth=1 -b ${{ github.ref_name }} https://github.com/ant-media/ant-media-server-parent.git || git clone --depth=1 https://github.com/ant-media/ant-media-server-parent.git | |
| cd ant-media-server-parent | |
| mvn clean install -DskipTests -Dmaven.javadoc.skip=true -Dgpg.skip=true --quiet | |
| cd .. | |
| - name: Clone and build server project | |
| run: | | |
| git clone --depth=1 -b ${{ github.ref_name }} https://github.com/ant-media/Ant-Media-Server.git || git clone --depth=1 https://github.com/ant-media/Ant-Media-Server.git | |
| cd Ant-Media-Server | |
| mvn clean install -DskipTests -Dmaven.javadoc.skip=true -Dgpg.skip=true --quiet | |
| cd .. | |
| - name: Install and compile npm packages | |
| run: | | |
| pwd | |
| ls -alh | |
| npm install | |
| npm run compile | |
| cd embedded-player | |
| npm install | |
| npm run compile | |
| npm run deploy | |
| cd .. | |
| - name: Install Maven packages | |
| run: mvn install -DskipTests=true -Dmaven.javadoc.skip=true -Dgpg.skip=true -B -V --quiet | |
| - name: Deploy | |
| run: | | |
| export GPG_TTY=$(tty) | |
| gpg --list-keys | |
| mvn deploy -DskipTests --settings mvn-settings.xml | |
| env: | |
| # Add your Maven credentials as secrets | |
| CI_DEPLOY_USERNAME: ${{ secrets.CI_DEPLOY_USERNAME }} | |
| CI_DEPLOY_PASSWORD: ${{ secrets.CI_DEPLOY_PASSWORD }} | |
| GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} | |