Skip to content

Commit

Permalink
fix: publish conditions fix and documentation adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
mkolasinski-splunk committed Sep 25, 2024
1 parent 2bea7c1 commit 7f1f53c
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 3 deletions.
13 changes: 13 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
### Description

(PR description goes here)

### Checklist

- [ ] `README.md` has been updated or is not required
- [ ] push trigger tests
- [ ] manual release test
- [ ] automated releaes test
- [ ] pull request trigger tests
- [ ] schedule trigger tests
- [ ] workflow errors/warnings reviewed and addressed
5 changes: 3 additions & 2 deletions .github/workflows/reusable-build-test-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2333,7 +2333,7 @@ jobs:
summary-scripted*
pre-publish:
if: ${{ !cancelled() && needs.validate-custom-version.result == 'success' }}
if: ${{ !cancelled() }}
# The following line will rename 'pre-publish' to 'pre-publish-not_main_pr' when PR is created towards main branch
# It is necessary to avoid confusion caused by githubactions considering pre-publish for both push to develop branch
# and pull_request to main branch events.
Expand Down Expand Up @@ -2377,8 +2377,9 @@ jobs:
publish:
if: |
(!cancelled() && needs.pre-publish.result == 'success' && github.event_name != 'pull_request' && github.event_name != 'schedule') ||
(!cancelled() && needs.pre-publish.result == 'success' && github.event_name == 'push' && github.event.inputs.custom-version == '') ||
(!cancelled() && needs.pre-publish.result == 'success' && github.event.inputs.custom-version != '' && needs.validate-custom-version.result == 'success')
# First condition for standard release process, second one for manual custom-version release process
name: ${{ github.event.inputs.custom-version == '' && 'publish' || 'publish-custom-version' }}

needs:
Expand Down
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,25 @@ Workflow defines jobs which perform security code scanning, execute different ty
* If bugfix release is needed:
* make a change
* test it
* pull-request scenario
* push scenario
* release scenario (test-addonfactory-repository)
* create a PR to the `main` branch
* get all the approvals from the team
* merge it using "squash commit" option
* backport the change back to the `develop` branch
* new version of the workflow is going to be released (v4.17.0 (before) -> v4.17.1 (after)) and it will automatically applied to all the repositories

# Troubleshooting for different workflow stages in GitHub Actions
# Workflow jobs

## Inputs
* marker - list of markers used to paralelize modinput tests
* ui_marker - list of markers used to paralelize ui tests
* custom-version - version used for release on manual workflow trigger
* execute-tests-on-push-to-release - enable tests on release branch - default false
* k8s-enfironment - k8s environment for testing
* k8s-manifests-branch - k8s-manifests branch for testing
* scripted-inputs-os-list - list of OSes used for scripted inputs tests

## General troubleshooting

Expand Down

0 comments on commit 7f1f53c

Please sign in to comment.