add test apps #36
Workflow file for this run
This file contains 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
"on": | |
push: | |
branches: | |
- dgtown/canary | |
name: Run integration tests | |
jobs: | |
integration-tests: | |
name: Run integration tests | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
yaml: ['js-test-app-buildpack', 'js-test-app-dockerfile', 'nginx', 'next-test-app-dockerfile'] | |
fail-fast: false | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
repository: porter-dev/app-integration-tests | |
ref: refs/heads/main | |
- name: Run test | |
uses: ./.github/actions | |
with: | |
host: https://dashboard.internal-tools.porter.run | |
project: "301" | |
cluster: "142" | |
token: ${{ secrets.APP_INTEGRATION_PROJECT_TOKEN }} | |
yaml_file: ./test-yamls/${{ matrix.yaml }}.yaml | |
notify-on-failure: | |
name: Notify on failure | |
needs: integration-tests | |
runs-on: ubuntu-latest | |
if: failure() | |
steps: | |
- name: Notify Slack on failure | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.APP_INTEGRATION_SLACK_WEBHOOK }} | |
RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} | |
REPO: ${{ github.repository }} | |
run: | | |
curl -X POST -H 'Content-type: application/json' --data "{\"text\":\"@porter-support \`$REPO\` integration tests failed in `internal-tools`: $RUN_URL \"}" $SLACK_WEBHOOK_URL |