updates updates updates #1
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Docker scenarios | ||
| run-name: Docker scenarios | ||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| test_scenarios: | ||
| description: 'A regexp to select what docker scenarios should be run' | ||
| required: false | ||
| type: string | ||
| default: '.*' | ||
| jobs: | ||
| docker-scenarios: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| -uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | ||
| - name: Set up Go | ||
| uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0 | ||
| with: | ||
| go-version: 1.25.1 | ||
| # Perf event paranoid setting: Not useful to everyone | ||
| - name: Update perf_event_paranoid settings | ||
| run: sudo sysctl kernel.perf_event_paranoid=1 | ||
| - name: Run Docker scenarios | ||
| run: go test -v -run TestScenarios | ||
| env: | ||
| TEST_SCENARIOS: ${{ inputs.test_scenarios }} | ||
| - name: Create unique artifact name | ||
| id: artifact_name | ||
| if: failure() | ||
| run: | | ||
| # Replace special characters with underscores to make it artifact-name safe | ||
| SAFE_NAME=$(echo "${{ inputs.test_scenarios }}" | sed 's/[^a-zA-Z0-9]/_/g') | ||
| echo "name=docker_scenario_test_data_${SAFE_NAME}_${{ github.run_id }}" >> $GITHUB_OUTPUT | ||
| - name: Upload test files | ||
| uses: actions/upload-artifact@v4 | ||
| if: failure() | ||
| with: | ||
| name: ${{ steps.artifact_name.outputs.name }} | ||
| path: data | ||
| - name: Notify Slack | ||
| if: failure() && github.ref == 'refs/heads/main' | ||
| run: | | ||
| curl -X POST "${{ secrets.SLACK_WEBHOOK }}" \ | ||
| -H 'Content-Type: application/json' \ | ||
| -d "{'scenarios': '${{ inputs.test_scenarios }}', 'failed_run_url': '${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}'}" | ||