Skip to content

fix(deps): update vertxversion to v4.5.11 #1026

fix(deps): update vertxversion to v4.5.11

fix(deps): update vertxversion to v4.5.11 #1026

Workflow file for this run

name: Build CLI interface
on:
push:
branches: [ master ]
paths-ignore:
- '**.md'
- '**.svg'
pull_request:
branches: [ master ]
paths-ignore:
- '**.md'
- '**.svg'
workflow_dispatch:
jobs:
buildOnMac:
runs-on: macos-latest
timeout-minutes: 20
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-buildOnMac
cancel-in-progress: true
steps:
- uses: actions/checkout@v4
- uses: ayltai/setup-graalvm@v1
with:
java-version: 11
graalvm-version: 22.2.0
native-image: true
- name: Export Properties
id: properties
shell: bash
run: |
PROPERTIES="$(./gradlew properties --console=plain -q)"
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')"
echo "::set-output name=version::$VERSION"
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
- name: Build native spp-cli (Release)
if: github.ref == 'refs/heads/master'
run: gradle assemble nativeImage -Dbuild.profile=release -PcliVersion=$SPP_RELEASE_VERSION
- name: Build native spp-cli (Snapshot)
if: github.ref != 'refs/heads/master'
run: gradle assemble nativeImage -Dbuild.profile=release
- name: "[CLI] Get version"
run: ./build/graal/spp-cli -v version
- name: Compress CLI
uses: svenstaro/upx-action@v2
with:
file: build/graal/spp-cli
- name: Zip CLI
run: zip spp-cli-macOS.zip -j build/graal/spp-cli
- uses: actions/upload-artifact@v3
with:
name: spp-cli-macOS.zip
path: ./spp-cli-macOS.zip
buildOnWindows:
runs-on: windows-2019
timeout-minutes: 20
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-buildOnWindows
cancel-in-progress: true
steps:
- uses: actions/checkout@v4
- uses: microsoft/[email protected]
- uses: seanmiddleditch/gha-setup-vsdevenv@master
- uses: ayltai/setup-graalvm@v1
with:
java-version: 11
graalvm-version: 22.2.0
native-image: true
- name: Export Properties
id: properties
shell: bash
run: |
PROPERTIES="$(./gradlew properties --console=plain -q)"
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')"
echo "::set-output name=version::$VERSION"
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
- name: Build native spp-cli.exe (Release)
if: github.ref == 'refs/heads/master'
run: ./gradlew assemble nativeImage '-Dbuild.profile=release' '-PcliVersion=$SPP_RELEASE_VERSION'
shell: powershell
- name: Build native spp-cli.exe (Snapshot)
if: github.ref != 'refs/heads/master'
run: ./gradlew assemble nativeImage '-Dbuild.profile=release'
shell: powershell
- name: "[CLI] Get version"
run: ./build/graal/spp-cli -v version
- name: Run UPX
uses: crazy-max/[email protected]
with:
version: latest
file: build/graal/spp-cli.exe
args: '-7'
- name: Zip CLI
run: Compress-Archive -LiteralPath build/graal/spp-cli.exe -DestinationPath spp-cli-win64.zip
shell: powershell
- uses: actions/upload-artifact@v3
with:
if-no-files-found: warn
name: spp-cli-win64.zip
path: ./spp-cli-win64.zip
buildOnLinux:
runs-on: ubuntu-latest
timeout-minutes: 20
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-buildOnLinux
cancel-in-progress: true
outputs:
version: ${{ steps.properties.outputs.version }}
release_version: ${{ steps.properties.outputs.release_version }}
steps:
- uses: actions/checkout@v4
- uses: ayltai/setup-graalvm@v1
with:
java-version: 11
graalvm-version: 22.2.0
native-image: true
- name: Export Properties
id: properties
shell: bash
run: |
PROPERTIES="$(./gradlew properties --console=plain -q)"
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')"
echo "::set-output name=version::$VERSION"
echo "SPP_CLI_VERSION=$VERSION" >> $GITHUB_ENV
echo "SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}" >> $GITHUB_ENV
SPP_RELEASE_VERSION=${VERSION/-SNAPSHOT/}
echo "::set-output name=release_version::$SPP_RELEASE_VERSION"
- name: Build native spp-cli (Release)
if: github.ref == 'refs/heads/master'
run: ./gradlew assembleUp nativeImage -Dbuild.profile=release -PcliVersion=$SPP_RELEASE_VERSION
- name: Build native spp-cli (Snapshot)
if: github.ref != 'refs/heads/master'
run: ./gradlew assembleUp nativeImage -Dbuild.profile=release
- name: Docker IPs
run: docker inspect --format='{{.Name}} - {{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -aq)
- name: Set SPP_PLATFORM_HOST
run: SPP_PLATFORM_HOST=$(docker inspect -f '{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -aqf "name=spp-platform")) && echo "SPP_PLATFORM_HOST=$SPP_PLATFORM_HOST" >> $GITHUB_ENV
- name: "[CLI] Get version"
run: ./build/graal/spp-cli -v version
- name: "[CLI] Get developers"
run: ./build/graal/spp-cli -v admin get-developers
- name: "[CLI] Add developer"
run: ./build/graal/spp-cli -v admin add-developer test
- name: "[CLI] Refresh authorization code"
run: ./build/graal/spp-cli -v admin refresh-authorization-code test
- name: "[CLI] Get roles"
run: ./build/graal/spp-cli -v admin get-roles
- name: "[CLI] Get role permissions"
run: ./build/graal/spp-cli -v admin get-role-permissions role_manager
- name: "[CLI] Add role"
run: ./build/graal/spp-cli -v admin add-role tester
- name: "[CLI] Add role permission"
run: ./build/graal/spp-cli -v admin add-role-permission tester ADD_DEVELOPER
- name: "[CLI] Add developer role"
run: ./build/graal/spp-cli -v admin add-developer-role test tester
- name: "[CLI] Get developer roles"
run: ./build/graal/spp-cli -v admin get-developer-roles test
- name: "[CLI] Get developer permissions"
run: ./build/graal/spp-cli -v admin get-developer-permissions test
- name: "[CLI] Add access permission"
run: ACCESS_PERMISSION_ID=$(./build/graal/spp-cli -v admin add-access-permission -l spp.example.webapp.model.User WHITE_LIST | grep -oP '(?<="id"\s:\s")[^"]*') && echo "ACCESS_PERMISSION_ID=$ACCESS_PERMISSION_ID" >> $GITHUB_ENV
- name: "[CLI] Add role access permission"
run: ./build/graal/spp-cli -v admin add-role-access-permission tester ${{ env.ACCESS_PERMISSION_ID }}
- name: "[CLI] Get access permissions"
run: ./build/graal/spp-cli -v admin get-access-permissions
- name: "[CLI] Get developer access permissions"
run: ./build/graal/spp-cli -v admin get-developer-access-permissions test
- name: "[CLI] Get role access permissions"
run: ./build/graal/spp-cli -v admin get-role-access-permissions tester
- name: "[CLI] Remove role access permission"
run: ./build/graal/spp-cli -v admin remove-role-access-permission tester ${{ env.ACCESS_PERMISSION_ID }}
- name: "[CLI] Remove access permission"
run: ./build/graal/spp-cli -v admin remove-access-permission ${{ env.ACCESS_PERMISSION_ID }}
- name: "[CLI] Remove developer role"
run: ./build/graal/spp-cli -v admin remove-developer-role test tester
- name: "[CLI] Remove role permission"
run: ./build/graal/spp-cli -v admin remove-role-permission tester ADD_DEVELOPER
- name: "[CLI] Remove role"
run: ./build/graal/spp-cli -v admin remove-role tester
- name: "[CLI] Remove developer"
run: ./build/graal/spp-cli -v admin remove-developer test
- name: "[CLI] Add live breakpoint"
run: ./build/graal/spp-cli -v add breakpoint -h 100 spp.example.webapp.model.User 48
- name: "[CLI] Add live log"
run: ./build/graal/spp-cli -v add log -h 100 spp.example.webapp.model.User 48 test-message
- name: "[CLI] Get live instruments"
run: ./build/graal/spp-cli -v get instruments
- name: "[CLI] Get live breakpoints"
run: ./build/graal/spp-cli -v get breakpoints
- name: "[CLI] Get live logs"
run: ./build/graal/spp-cli -v get logs
- name: "[CLI] Remove live instruments"
run: ./build/graal/spp-cli -v remove instruments spp.example.webapp.model.User 48
- name: Check CLI
run: ./gradlew check -Dtest.profile=integration
- name: Compress CLI
uses: svenstaro/upx-action@v2
with:
file: build/graal/spp-cli
- name: Zip spp-cli
run: zip spp-cli-linux64.zip -j build/graal/spp-cli
- uses: actions/upload-artifact@v3
with:
name: spp-cli-linux64.zip
path: ./spp-cli-linux64.zip
- run: ./gradlew composeLogs
if: ${{ !cancelled() }}
- name: Upload docker logs artifact
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v3
with:
name: docker-logs
path: ./build/containers-logs
releaseDraft:
name: Release Draft
needs: [ buildOnMac, buildOnWindows, buildOnLinux ]
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- name: Remove Old Release Drafts
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
curl -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/repos/$GITHUB_REPOSITORY/releases \
| tr '\r\n' ' ' \
| jq '.[] | select(.draft == true) | .id' \
| xargs -I '{}' \
curl -X DELETE -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/repos/$GITHUB_REPOSITORY/releases/{}
- name: Create Release Draft
id: createDraft
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ needs.buildOnLinux.outputs.release_version }}
release_name: v${{ needs.buildOnLinux.outputs.release_version }}
body: ${{ needs.build.outputs.changelog }}
draft: true
- name: Download spp-cli-macOS artifact
uses: actions/download-artifact@v3
with:
name: spp-cli-macOS.zip
- name: Upload spp-cli-macOS asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.createDraft.outputs.upload_url }}
asset_path: ./spp-cli-macOS.zip
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-macOS.zip
asset_content_type: application/zip
- name: Download spp-cli-win64 artifact
uses: actions/download-artifact@v3
with:
name: spp-cli-win64.zip
- name: Upload spp-cli-win64 asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.createDraft.outputs.upload_url }}
asset_path: ./spp-cli-win64.zip
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-win64.zip
asset_content_type: application/zip
- name: Download spp-cli-linux64 artifact
uses: actions/download-artifact@v3
with:
name: spp-cli-linux64.zip
- name: Upload spp-cli-linux64 asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.createDraft.outputs.upload_url }}
asset_path: ./spp-cli-linux64.zip
asset_name: spp-cli-${{ needs.buildOnLinux.outputs.release_version }}-linux64.zip
asset_content_type: application/zip