Merge pull request #239 from protegeproject/manage-hierarchies-menu-item #420
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: Release | |
| on: | |
| push: | |
| branches: | |
| - master | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| if: ${{ github.actor != 'protegeproject-bot[bot]' }} | |
| outputs: | |
| version: ${{ steps.release-outputs.outputs.version }} | |
| service: ${{ steps.release-outputs.outputs.service }} | |
| steps: | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@v2 | |
| with: | |
| username: ${{secrets.DOCKER_USERNAME}} | |
| password: ${{secrets.DOCKER_PASSWORD}} | |
| - uses: actions/create-github-app-token@v1 | |
| id: app-token | |
| with: | |
| app-id: ${{ vars.PROTEGEPROJECT_BOT_APP_ID }} | |
| private-key: ${{ secrets.PROTEGEPROJECT_BOT_APP_PRIVATE_KEY }} | |
| - uses: actions/checkout@v4 | |
| with: | |
| token: ${{ steps.app-token.outputs.token }} | |
| ref: ${{ github.head_ref }} | |
| - name: Set up Maven Central Repository | |
| uses: actions/setup-java@v3 | |
| with: | |
| java-version: '17' | |
| distribution: 'adopt' | |
| server-id: docker.io | |
| server-username: DOCKER_USERNAME | |
| server-password: DOCKER_PASSWORD | |
| - name: Bump version | |
| id: bump | |
| uses: mickem/gh-action-bump-maven-version@v1 | |
| - name: Build package | |
| run: mvn --batch-mode clean package | |
| - name: Build and push image | |
| run: mvn --batch-mode -pl webprotege-gwt-ui-server -am package install | |
| - name: Release | |
| uses: softprops/action-gh-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| tag_name: ${{ steps.bump.outputs.tag }} | |
| generate_release_notes: true | |
| - name: Set outputs | |
| id: release-outputs | |
| run: | | |
| echo "version=${{ steps.bump.outputs.tag }}" >> $GITHUB_OUTPUT | |
| echo "service=webprotege-gwt-ui-server" >> $GITHUB_OUTPUT | |
| notify-bump: | |
| needs: build | |
| uses: ./.github/workflows/notify-deploy-project.yaml | |
| with: | |
| version: ${{ needs.build.outputs.version }} | |
| service: ${{ needs.build.outputs.service }} | |
| branch_var: ${{vars.BUMP_WEBPROTEGE_BRANCH}} | |
| secrets: | |
| PROTEGE_PROJECT_CLIENT_ID: ${{ secrets.PROTEGE_PROJECT_CLIENT_ID }} | |
| PROTEGE_PROJECT_CLIENT_SECRET: ${{ secrets.PROTEGE_PROJECT_CLIENT_SECRET }} | |
| env: | |
| DOCKER_USERNAME: ${{secrets.DOCKER_USERNAME}} | |
| DOCKER_TOKEN: ${{secrets.DOCKER_PASSWORD}} |