Make WordPress Core


Ignore:
Timestamp:
06/30/2022 04:26:30 PM (4 years ago)
Author:
desrosj
Message:

Build/Test Tools: Use the Slack notifications workflow as a reusable one.

This backports several changesets that are required to remove the reliance on the workflow_run event for posting Slack notifications.

The Slack notification workflow will now be called as a reusable one, which has several benefits (see [53591]).

Several other minor GitHub Actions related updates are also being backported in this commit to maintain tooling consistency across branches that still receive security updates as a courtesy when necessary.

Merges [51921], [51924], [51925], [51937], [52002], [52130], [52183], [52233], [53112], [53581], [53582], [53592] to the 5.8 branch.
See #56095.

Location:
branches/5.8
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.8

  • branches/5.8/.github/workflows/php-compatibility.yml

    r51357 r53597  
    55  push:
    66    branches:
    7       - master
    87      - trunk
    98      - '5.[5-9]'
     
    1413  pull_request:
    1514    branches:
    16       - master
    1715      - trunk
    1816      - '5.[5-9]'
     
    4543  # - Checks out the repository.
    4644  # - Sets up PHP.
    47   # - Logs debug information about the runner container.
     45  # - Logs debug information about the GitHub Action runner.
    4846  # - Installs Composer dependencies (use cache if possible).
    4947  # - Make Composer packages available globally.
     
    5250  # - Ensures version-controlled files are not modified or deleted.
    5351  # - todo: Configure Slack notifications for failing scans.
    54   php-comatibility:
     52  php-compatibility:
    5553    name: Check PHP compatibility
    5654    runs-on: ubuntu-latest
     55    timeout-minutes: 20
    5756    if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
    5857
    5958    steps:
    6059      - name: Checkout repository
    61         uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
     60        uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
    6261
    6362      - name: Set up PHP
    64         uses: shivammathur/setup-php@afefcaf556d98dc7896cca380e181decb609ca44 # v2.10.0
     63        uses: shivammathur/setup-php@3eda58347216592f618bb1dff277810b6698e4ca # v2.19.1
    6564        with:
    6665          php-version: '7.4'
     
    7473
    7574      - name: Install Composer dependencies
    76         uses: ramsey/composer-install@92a7904348d4ad30236f3611e33b7f0c6f9edd70 # v1.1.0
     75        uses: ramsey/composer-install@f680dac46551dffb2234a240d65ae806c2999dd6 # v2.1.0
    7776        with:
    7877          composer-options: "--no-progress --no-ansi --no-interaction"
     
    8988      - name: Ensure version-controlled files are not modified or deleted
    9089        run: git diff --exit-code
     90
     91  slack-notifications:
     92    name: Slack Notifications
     93    uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
     94    needs: [ php-compatibility ]
     95    if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
     96    with:
     97      calling_status: ${{ needs.php-compatibility.result == 'success' && 'success' || needs.php-compatibility.result == 'cancelled' && 'cancelled' || 'failure' }}
     98    secrets:
     99      SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }}
     100      SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }}
     101      SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }}
     102      SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }}
Note: See TracChangeset for help on using the changeset viewer.