2022-03-30 04:29:49 -04:00
|
|
|
name: "Pull Request: Validate"
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
|
|
|
|
concurrency:
|
|
|
|
group: ${{ github.head_ref }}-pr-validate
|
|
|
|
# cancel-in-progress: true
|
|
|
|
|
|
|
|
jobs:
|
2023-05-25 04:56:29 -04:00
|
|
|
pr-changes:
|
|
|
|
name: Collect PR changes
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
outputs:
|
|
|
|
addedOrModified: ${{ steps.collect-changes.outputs.changesDetected }}
|
|
|
|
addedOrModifiedFiles: ${{ steps.collect-changes.outputs.addedOrModifiedFiles }}
|
|
|
|
addedOrModifiedCharts: ${{ steps.collect-changes.outputs.addedOrModifiedCharts }}
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-10-17 13:24:19 -04:00
|
|
|
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
2023-05-25 04:56:29 -04:00
|
|
|
|
|
|
|
- name: Collect changes
|
|
|
|
id: collect-changes
|
|
|
|
uses: ./.github/actions/collect-changes
|
2022-03-30 04:35:37 -04:00
|
|
|
|
2022-03-30 04:29:49 -04:00
|
|
|
charts-lint:
|
2022-03-30 04:51:01 -04:00
|
|
|
uses: ./.github/workflows/charts-lint.yaml
|
2022-03-30 04:35:37 -04:00
|
|
|
needs:
|
2023-05-25 04:56:29 -04:00
|
|
|
- pr-changes
|
2022-03-30 04:29:49 -04:00
|
|
|
with:
|
|
|
|
checkoutCommit: ${{ needs.charts-changelog.outputs.commitHash }}
|
2023-05-25 04:56:29 -04:00
|
|
|
chartChangesDetected: ${{ needs.pr-changes.outputs.addedOrModified }}
|
2023-05-28 13:28:55 -04:00
|
|
|
modifiedFiles: ${{ needs.pr-changes.outputs.addedOrModifiedFiles }}
|
|
|
|
modifiedCharts: ${{ needs.pr-changes.outputs.addedOrModifiedCharts }}
|
2022-03-30 04:29:49 -04:00
|
|
|
charts-test:
|
2022-03-30 04:51:01 -04:00
|
|
|
uses: ./.github/workflows/charts-test.yaml
|
2022-03-30 04:29:49 -04:00
|
|
|
needs:
|
2023-05-25 04:56:29 -04:00
|
|
|
- pr-changes
|
2022-03-30 04:29:49 -04:00
|
|
|
- charts-lint
|
|
|
|
with:
|
|
|
|
checkoutCommit: ${{ needs.charts-changelog.outputs.commitHash }}
|
2023-05-25 04:56:29 -04:00
|
|
|
chartChangesDetected: ${{ needs.pr-changes.outputs.addedOrModified }}
|
2023-05-28 13:28:55 -04:00
|
|
|
modifiedCharts: ${{ needs.pr-changes.outputs.addedOrModifiedCharts }}
|
2022-03-30 06:26:37 -04:00
|
|
|
|
|
|
|
catalog-test:
|
|
|
|
uses: ./.github/workflows/catalog-test.yaml
|
|
|
|
needs:
|
2023-05-25 04:56:29 -04:00
|
|
|
- pr-changes
|
2022-03-30 06:26:37 -04:00
|
|
|
with:
|
|
|
|
checkoutCommit: ${{ needs.charts-changelog.outputs.commitHash }}
|
2023-05-25 04:56:29 -04:00
|
|
|
chartChangesDetected: ${{ needs.pr-changes.outputs.addedOrModified }}
|
2024-02-20 19:22:20 -05:00
|
|
|
modifiedCharts: ${{ needs.pr-changes.outputs.addedOrModifiedCharts }}
|
2022-11-14 16:30:05 -05:00
|
|
|
|
|
|
|
print_head_msg:
|
|
|
|
name: print commit message
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
outputs:
|
|
|
|
head-commit-message: ${{ steps.get_head_commit_message.outputs.headCommitMsg }}
|
|
|
|
steps:
|
|
|
|
- name: Get repo
|
2023-10-17 13:24:19 -04:00
|
|
|
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
2022-11-14 16:30:05 -05:00
|
|
|
with:
|
|
|
|
ref: ${{ github.event.pull_request.head.sha }}
|
2022-11-15 05:36:31 -05:00
|
|
|
- name: verbose head git commit message
|
|
|
|
run: echo "$(git show -s --format=%s)"
|
2022-11-14 16:30:05 -05:00
|
|
|
- name: Print head git commit message
|
|
|
|
id: get_head_commit_message
|
|
|
|
run: echo "::set-output name=headCommitMsg::$(git show -s --format=%s)"
|
|
|
|
|
2023-02-06 12:29:56 -05:00
|
|
|
automerge-and-approve:
|
2022-11-14 16:30:05 -05:00
|
|
|
needs:
|
2023-05-25 04:56:29 -04:00
|
|
|
- pr-changes
|
2022-11-14 16:30:05 -05:00
|
|
|
- catalog-test
|
|
|
|
- charts-test
|
|
|
|
- charts-lint
|
2023-11-30 05:56:37 -05:00
|
|
|
- print_head_msg
|
2023-12-17 07:59:32 -05:00
|
|
|
if: ${{ contains( needs.print_head_msg.outputs.head-commit-message, 'By Renovate' ) }}
|
2023-02-06 12:29:56 -05:00
|
|
|
name: Automerge and Approve build
|
2022-11-14 16:30:05 -05:00
|
|
|
runs-on: ubuntu-latest
|
2024-03-16 09:16:11 -04:00
|
|
|
continue-on-error: true
|
2022-11-14 16:30:05 -05:00
|
|
|
steps:
|
2023-02-06 12:29:56 -05:00
|
|
|
- uses: hmarr/auto-approve-action@v3
|
|
|
|
with:
|
2023-02-06 12:42:27 -05:00
|
|
|
github-token: "${{ secrets.PERS_PAT }}"
|
2022-11-14 16:30:05 -05:00
|
|
|
- name: automerge
|
2024-04-12 02:16:26 -04:00
|
|
|
uses: pascalgn/automerge-action@d1203c0bf94a827b991e5de69d662e9163304fa0 # v0.16.3
|
2022-11-14 16:30:05 -05:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: "${{ secrets.BOT_TOKEN }}"
|
|
|
|
UPDATE_RETRIES: 12
|
|
|
|
UPDATE_RETRY_SLEEP: 60000
|
2023-04-29 09:25:22 -04:00
|
|
|
MERGE_METHOD: squash
|