Skip to content

Commit

Permalink
minor refactorings
Browse files Browse the repository at this point in the history
  • Loading branch information
riprasad committed Oct 7, 2021
1 parent 399bdad commit 50a4280
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 52 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/release-cli.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:


jobs:
build-linux-cli:
release-linux-cli:
if: github.repository_owner == 'Apicurio' && (github.event_name == 'release' || github.event.inputs.release-linux-cli == 'true')
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -102,13 +102,13 @@ jobs:
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
name: ${{ github.job }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}



build-macos-cli:
release-macos-cli:
if: github.repository_owner == 'Apicurio' && (github.event_name == 'release' || github.event.inputs.release-macos-cli == 'true')
runs-on: macos-latest
steps:
Expand Down Expand Up @@ -179,13 +179,13 @@ jobs:
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
name: ${{ github.job }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}



build-win64-cli:
release-win64-cli:
if: github.repository_owner == 'Apicurio' && (github.event_name == 'release' || github.event.inputs.release-win64-cli == 'true')
runs-on: windows-2019
steps:
Expand Down Expand Up @@ -277,6 +277,6 @@ jobs:
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
name: ${{ github.job }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}
46 changes: 2 additions & 44 deletions .github/workflows/release-images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,48 +84,6 @@ jobs:
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
name: ${{ github.job }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}

verify-release:
runs-on: ubuntu-18.04
needs: ["release-images"] # The Job gets triggered only after the "release-images" job has successfully completed. The job doesn't run in case the "release-images" job fails
if: github.repository_owner == 'Apicurio'
steps:

- name: Fetch required Details
run: |
touch latestRelease.json && curl https://api.github.com/repos/apicurio/apicurio-registry/releases/latest > latestRelease.json
echo "RELEASE_VERSION=$(cat latestRelease.json | jq '.name' | sed 's/"//g')" >> $GITHUB_ENV
echo "SOURCE_CODE_URL=$(cat latestRelease.json | jq '.zipball_url' | sed 's/"//g')" >> $GITHUB_ENV
echo "BRANCH=$(cat latestRelease.json | jq '.target_commitish' | sed 's/"//g')" >> $GITHUB_ENV
- name: Checkout Code with Ref '${{ github.ref }}'
uses: actions/checkout@v2

- name: Determine Floating Tag
run: |
if [[ $BRANCH == 'master' ]]
then
echo "FLOATING_TAG=latest-release" >> $GITHUB_ENV
else
echo "FLOATING_TAG=$BRANCH-release" >> $GITHUB_ENV
fi
- name: Verify Docker Release For mem
run: cd apicurio-registry && ./.github/scripts/verify-docker-release.sh apicurio/apicurio-registry-mem:${RELEASE_VERSION} apicurio/apicurio-registry-mem:${FLOATING_TAG}

- name: Verify Docker Release For sql
run: cd apicurio-registry && ./.github/scripts/verify-docker-release.sh apicurio/apicurio-registry-sql:${RELEASE_VERSION} apicurio/apicurio-registry-sql:${FLOATING_TAG}

- name: Verify Docker Release For kafkasql
run: cd apicurio-registry && ./.github/scripts/verify-docker-release.sh apicurio/apicurio-registry-kafkasql:${RELEASE_VERSION} apicurio/apicurio-registry-kafkasql:${FLOATING_TAG}

- name: Google Chat Notification
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}
status: ${{ job.status }}
4 changes: 2 additions & 2 deletions .github/workflows/update-website.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
types: [released]

jobs:
release-images:
update-website:
if: github.repository_owner == 'Apicurio'
runs-on: ubuntu-18.04
steps:
Expand Down Expand Up @@ -70,6 +70,6 @@ jobs:
if: ${{ failure() }}
uses: Co-qn/google-chat-notification@releases/v1
with:
name: ${{ github.workflow }}
name: ${{ github.job }}
url: ${{ secrets.GOOGLE_CHAT_WEBHOOK }}
status: ${{ job.status }}

0 comments on commit 50a4280

Please sign in to comment.