Release workflows refactoring (#733)
Signed-off-by: Mykhailo Kuznietsov <mkuznets@redhat.com>pull/738/head
parent
8e99287eec
commit
8724853a84
|
|
@ -16,7 +16,7 @@ on:
|
|||
branches:
|
||||
- master
|
||||
paths:
|
||||
- 'deploy/olm-catalog/stable/eclipse-che-preview-*/manifests/che-operator.clusterserviceversion.yaml'
|
||||
- 'VERSION'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ on:
|
|||
branches:
|
||||
- master
|
||||
paths:
|
||||
- 'deploy/olm-catalog/stable/eclipse-che-preview-*/manifests/che-operator.clusterserviceversion.yaml'
|
||||
- 'VERSION'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ on:
|
|||
branches:
|
||||
- master
|
||||
paths:
|
||||
- 'deploy/olm-catalog/stable/eclipse-che-preview-*/manifests/che-operator.clusterserviceversion.yaml'
|
||||
- 'VERSION'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
|
|
|||
|
|
@ -93,10 +93,15 @@ jobs:
|
|||
git checkout ${BRANCH}
|
||||
git checkout ${CHE_VERSION}-release
|
||||
./make-release.sh ${CHE_VERSION} --push-git-changes --pull-requests ${{ github.event.inputs.force_update }}
|
||||
- name: Create MM message
|
||||
- name: Create failure MM message
|
||||
if: ${{ failure() }}
|
||||
run: |
|
||||
echo "{\"text\":\":building_construction: Che Operator ${{ github.event.inputs.version }} has been released: https://quay.io/eclipse/che-operator:${{ github.event.inputs.version }}\"}" > mattermost.json
|
||||
echo "{\"text\":\":building_construction: Che Operator ${{ github.event.inputs.version }} release has failed: https://github.com/eclipse-che/che-operator/actions/workflows/release.yml\"}" > mattermost.json
|
||||
- name: Create success MM message
|
||||
run: |
|
||||
echo "{\"text\":\":building_construction: Che Operator ${{ github.event.inputs.version }} release PR have been created: https://github.com/eclipse-che/che-operator/pulls/che-bot\"}" > mattermost.json
|
||||
- name: Send MM message
|
||||
if: ${{ success() }} || ${{ failure() }}
|
||||
uses: mattermost/action-mattermost-notify@master
|
||||
env:
|
||||
MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_WEBHOOK_URL }}
|
||||
|
|
|
|||
|
|
@ -181,6 +181,13 @@ updateNightlyOlmFiles() {
|
|||
fi
|
||||
}
|
||||
|
||||
updateVersionFile() {
|
||||
echo "[INFO] updating VERSION file"
|
||||
echo ${RELEASE} > VERSION
|
||||
git add VERSION
|
||||
git commit -m "Update VERSION to $RELEASE" --signoff
|
||||
}
|
||||
|
||||
releaseOlmFiles() {
|
||||
echo "[INFO] releaseOlmFiles :: Release OLM files"
|
||||
echo "[INFO] releaseOlmFiles :: Launch 'olm/release-olm-files.sh' script"
|
||||
|
|
@ -257,6 +264,7 @@ prepareCommunityOperatorsUpdate() {
|
|||
}
|
||||
run() {
|
||||
checkoutToReleaseBranch
|
||||
updateVersionFile
|
||||
releaseOperatorCode
|
||||
if [[ $UPDATE_NIGHTLY_OLM_FILES == "true" ]]; then
|
||||
updateNightlyOlmFiles
|
||||
|
|
|
|||
Loading…
Reference in New Issue