Skip to content

Commit 9eb2051

Browse files
Create self_hosted_integration_issues.yml
Most of the self hosted tickets are because the user was following cloud docs. Adding a comment to improve that.
1 parent b5ebd1f commit 9eb2051

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Comment on self-hosted integration issues
2+
3+
on:
4+
issues:
5+
types: [opened]
6+
7+
jobs:
8+
comment:
9+
runs-on: ubuntu-latest
10+
permissions:
11+
issues: write
12+
steps:
13+
- name: Check if issue contains keywords
14+
id: check
15+
run: |
16+
body="${{ github.event.issue.body }}"
17+
shopt -s nocasematch
18+
if [[ "$body" == *"self-hosted (https://develop.sentry.dev/self-hosted/)"* && "$body" == *"integration"* && "$body" == *"sentry.io"* ]]; then
19+
echo "match=true" >> $GITHUB_OUTPUT
20+
else
21+
echo "match=false" >> $GITHUB_OUTPUT
22+
fi
23+
- name: Comment on issue
24+
if: steps.check.outputs.match == 'true'
25+
uses: actions/github-script@v7
26+
with:
27+
script: |
28+
github.rest.issues.createComment({
29+
issue_number: context.issue.number,
30+
owner: context.repo.owner,
31+
repo: context.repo.repo,
32+
body: "Hi! 👋 It looks like you're asking about an integration with self-hosted Sentry. Integrations work differently on self-hosted Sentry so we created separate docs here: https://develop.sentry.dev/integrations/. Please take a look and let us know if you need further help."
33+
})

0 commit comments

Comments
 (0)