forked from opensearch-project/security
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (38 loc) · 1.23 KB
/
issue-dedupe.yml
File metadata and controls
40 lines (38 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
name: Issue Dedupe Main
on:
issues:
types: [opened]
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
inputs:
issue_number:
description: 'Issue number to check for duplicates'
required: true
type: string
jobs:
detect-issue:
if: >-
(github.event_name == 'workflow_dispatch' &&
github.repository == 'opensearch-project/security') ||
(github.event_name == 'issues' &&
github.event.issue.user.type != 'Bot' &&
github.repository == 'opensearch-project/security')
uses: opensearch-project/opensearch-build/.github/workflows/issue-dedupe-detect.yml@main
permissions:
contents: read
issues: write
id-token: write
secrets:
BEDROCK_ACCESS_ROLE_ISSUE_DEDUPE: ${{ secrets.BEDROCK_ACCESS_ROLE_ISSUE_DEDUPE }}
with:
issue_number: ${{ inputs.issue_number || '' }}
grace_days: ${{ vars.DUPLICATE_GRACE_DAYS || '7' }}
auto-close-issue:
if: github.event_name == 'schedule' && github.repository == 'opensearch-project/security'
uses: opensearch-project/opensearch-build/.github/workflows/issue-dedupe-autoclose.yml@main
permissions:
issues: write
with:
grace_days: ${{ vars.DUPLICATE_GRACE_DAYS || '7' }}