Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Divide github workflows to maintain consistency across all repos #1823

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions .github/workflows/all_green_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,27 @@ on: # yamllint disable-line rule:truthy
- '*'

jobs:
changelog-and-linters:
uses: ./.github/workflows/changelog_and_linters.yml # use the callable changelog-and-linters job to run tests
changelog:
uses: ./.github/workflows/changelog.yml # use the callable changelog job to run tests
linters:
uses: ./.github/workflows/linters.yml # use the callable linters job to run tests
sanity:
uses: ./.github/workflows/sanity.yml # use the callable sanity job to run tests
units:
uses: ./.github/workflows/units.yml # use the callable units job to run tests
all_green:
if: ${{ always() }}
needs:
- changelog-and-linters
- changelog
- linters
- sanity
- units
runs-on: ubuntu-latest
steps:
- run: >-
python -c "assert set([
'${{ needs.changelog-and-linters.result }}',
'${{ needs.changelog.result }}',
'${{ needs.linters.result }}',
'${{ needs.sanity.result }}',
'${{ needs.units.result }}'
]) == {'success'}"
8 changes: 8 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: changelog and linters

on: [workflow_call] # allow this workflow to be called from other workflows

jobs:
changelog:
uses: ansible-network/github_actions/.github/workflows/changelog.yml@main
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ name: changelog and linters
on: [workflow_call] # allow this workflow to be called from other workflows

jobs:
changelog:
uses: ansible-network/github_actions/.github/workflows/changelog.yml@main
linters:
uses: ansible-network/github_actions/.github/workflows/tox.yml@main
with:
Expand Down