Skip to content

Commit

Permalink
allow /e2e in PRs to run e2e workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Manabu McCloskey <[email protected]>
  • Loading branch information
nabuskey committed Nov 26, 2024
1 parent 98b7234 commit 3061181
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
- '**.go'
- 'go.sum'
- 'go.mod'
repository_dispatch:
types: [e2e-command]
jobs:
e2e:
runs-on: ubuntu-22.04
Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/slash-commands.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: slash-commands

on:
issue_comment:
types: [created]

jobs:
slash_command_dispatch:
runs-on: ubuntu-22.04
steps:
- name: Generate a token
id: generate-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.CNOE_GH_WORKFLOW_TOKEN_APP_ID }}
private-key: ${{ secrets.CNOE_GH_WORKFLOW_TOKEN_PRIVATE_KEY }}
- name: Slash Command Dispatch
uses: peter-evans/slash-command-dispatch@v4
with:
token: ${{ steps.generate-token.outputs.token }}
commands: |
e2e
permission: write
issue-type: pull-request

0 comments on commit 3061181

Please sign in to comment.