Skip to content

Commit a92da00

Browse files
committed
feat(ci): add issue and PR management automation
Import issue/PR housekeeping workflows adapted from NVIDIA/aicr: - triage: label new issues needs-triage, infer component/* labels from the Component dropdown, conventional-commit scope, and title/body text - labeler: path-based component/* and doc labels on PRs - welcome: greet first-time issue and PR authors - lock-threads: lock issues/PRs closed for 90+ days - inactive-pr-reminder: nudge PRs idle 14-29 days before the stale bot Migrate issue taxonomy to native GitHub Issue Types: the bug and feature forms now set the Bug/Enhancement type instead of a label, gain a multi-select Component dropdown, and the bug/feature/epic/task/initiative labels are retired. Add needs-triage plus component/ci and component/tests with distinct hues, and drop the dead P0 exemption from the stale workflow. All external actions (actions/github-script, actions/labeler) match the SHAs already allowlisted for the org. Signed-off-by: Brian Lockwood <lockwobr@gmail.com>
1 parent b264019 commit a92da00

11 files changed

Lines changed: 706 additions & 67 deletions

File tree

.github/ISSUE_TEMPLATE/bug_report_form.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717
name: Bug Report
1818
description: File a bug report for Skyhook
1919
title: "[BUG]: "
20-
labels: ["bug"]
20+
type: Bug
21+
labels: ["needs-triage"]
2122

2223
body:
2324
- type: markdown
@@ -55,6 +56,24 @@ body:
5556
validations:
5657
required: true
5758

59+
- type: dropdown
60+
id: component
61+
attributes:
62+
label: Component
63+
description: Which part(s) of the project are affected? Select all that apply; this helps us route the issue.
64+
multiple: true
65+
options:
66+
- Operator (controller-manager)
67+
- Agent (package executor)
68+
- Helm chart
69+
- CLI (kubectl-skyhook)
70+
- CI / tooling
71+
- Tests (e2e / chainsaw)
72+
- Docs / examples
73+
- Other / Unknown
74+
validations:
75+
required: true
76+
5877
- type: textarea
5978
id: description
6079
attributes:
@@ -94,9 +113,9 @@ body:
94113
id: terms
95114
attributes:
96115
label: Code of Conduct
97-
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/NVIDIA/skyhook/blob/main/CODE_OF_CONDUCT.md).
116+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/NVIDIA/nodewright/blob/main/CODE_OF_CONDUCT.md).
98117
options:
99118
- label: I agree to follow Skyhook's Code of Conduct
100119
required: true
101-
- label: I have searched the [open bugs](https://github.com/NVIDIA/skyhook/issues?q=is%3Aopen+is%3Aissue+label%3Abug) and have found no duplicates for this bug report
120+
- label: I have searched the [open bugs](https://github.com/NVIDIA/nodewright/issues?q=is%3Aopen+is%3Aissue+type%3ABug) and have found no duplicates for this bug report
102121
required: true

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ blank_issues_enabled: true
1818

1919
contact_links:
2020
- name: Ask a Question
21-
url: https://github.com/NVIDIA/skyhook/discussions
21+
url: https://github.com/NVIDIA/nodewright/discussions
2222
about: Please ask any questions here.
2323
- name: Report a Security Vulnerability
2424
url: https://www.nvidia.com/object/submit-security-vulnerability.html

.github/ISSUE_TEMPLATE/feature_request_form.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818
name: Feature Request
1919
description: Request new or improved functionality
2020
title: "[FEA]: "
21-
labels: ["feature"]
21+
type: Enhancement
22+
labels: ["needs-triage"]
2223

2324
body:
2425
- type: markdown
@@ -49,6 +50,24 @@ body:
4950
validations:
5051
required: true
5152

53+
- type: dropdown
54+
id: component
55+
attributes:
56+
label: Component
57+
description: Which part(s) of the project would this affect? Select all that apply; this helps us route the request.
58+
multiple: true
59+
options:
60+
- Operator (controller-manager)
61+
- Agent (package executor)
62+
- Helm chart
63+
- CLI (kubectl-skyhook)
64+
- CI / tooling
65+
- Tests (e2e / chainsaw)
66+
- Docs / examples
67+
- Other / Unknown
68+
validations:
69+
required: true
70+
5271
- type: textarea
5372
id: problem
5473
attributes:
@@ -91,9 +110,9 @@ body:
91110
id: terms
92111
attributes:
93112
label: Code of Conduct
94-
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/NVIDIA/skyhook/blob/main/CODE_OF_CONDUCT.md).
113+
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/NVIDIA/nodewright/blob/main/CODE_OF_CONDUCT.md).
95114
options:
96115
- label: I agree to follow Skyhook's Code of Conduct
97116
required: true
98-
- label: I have searched the [open feature requests](https://github.com/NVIDIA/skyhook/issues?q=is%3Aopen+is%3Aissue+label%3A%22feature+request%22) and have found no duplicates for this feature request
117+
- label: I have searched the [open feature requests](https://github.com/NVIDIA/nodewright/issues?q=is%3Aopen+is%3Aissue+type%3AEnhancement) and have found no duplicates for this feature request
99118
required: true

.github/labeler.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
# SPDX-License-Identifier: Apache-2.0
3+
#
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
# Path-based PR labels for actions/labeler. Kept in sync with the component/*
18+
# label family in .github/labels.yml and the triage keyword maps in
19+
# .github/workflows/triage.yaml.
20+
21+
# Operator (controller-manager), excluding the CLI which lives under it.
22+
component/operator:
23+
- changed-files:
24+
- any-glob-to-any-file:
25+
- 'operator/**'
26+
- all-globs-to-all-files:
27+
- '!operator/cmd/cli/**'
28+
29+
component/cli:
30+
- changed-files:
31+
- any-glob-to-any-file:
32+
- 'operator/cmd/cli/**'
33+
34+
component/agent:
35+
- changed-files:
36+
- any-glob-to-any-file:
37+
- 'agent/**'
38+
39+
component/chart:
40+
- changed-files:
41+
- any-glob-to-any-file:
42+
- 'chart/**'
43+
44+
component/ci:
45+
- changed-files:
46+
- any-glob-to-any-file:
47+
- '.github/**'
48+
- 'scripts/**'
49+
- '.gitlab-ci.yml'
50+
- '**/Makefile'
51+
- '**/*.mk'
52+
# Don't let vendored third-party Makefiles trip the CI label.
53+
- all-globs-to-all-files:
54+
- '!**/vendor/**'
55+
56+
component/tests:
57+
- changed-files:
58+
- any-glob-to-any-file:
59+
- 'k8s-tests/**'
60+
61+
doc:
62+
- changed-files:
63+
- any-glob-to-any-file:
64+
- 'docs/**'
65+
- '**/*.md'

.github/labels.yml

Lines changed: 33 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -19,83 +19,58 @@
1919
# Sync to GitHub with: make labels
2020
#
2121
# Label categories:
22-
# Issue types — applied automatically by issue templates
23-
# Component — which part of the project is affected
24-
# Planning — applied by engineering/product during triage (per DGXC OSS Policy)
25-
# Priority — P0/P1/P2 per DGXC OSS Policy, applied by engineering
26-
# Lifecycle — stale automation and freeze exemptions
27-
# Standard — common GitHub labels
28-
29-
# ── Issue Types ───────────────────────────────────────────────────────────────
30-
# Applied automatically by issue templates
31-
32-
- name: "bug"
33-
color: "d73a4a"
34-
description: "Something isn't working"
35-
36-
- name: "feature request"
37-
color: "a2eeef"
38-
description: "New feature or improvement to existing functionality"
22+
# Type: issue Type (Bug/Enhancement/Documentation/Task/Epic/Initiative) is
23+
# a native GitHub Issue Type set by the org, not a label
24+
# Triage: needs-triage, cleared once a maintainer triages
25+
# Component: which part of the project is affected
26+
# Lifecycle: stale automation and freeze exemptions
27+
# Standard: common GitHub labels
28+
29+
# ── Type ──────────────────────────────────────────────────────────────────────
30+
# Bug / Enhancement / Documentation / Task / Epic / Initiative are native GitHub
31+
# Issue Types (org-level), assigned by the issue forms via their `type:` key, not
32+
# labels. `doc` stays as a label because the PR path labeler applies it to
33+
# docs-only PRs (issues use the Documentation type instead).
3934

4035
- name: "doc"
4136
color: "0075ca"
42-
description: "Documentation addition, correction, or improvement"
37+
description: "Documentation change (PR path label; doc issues use the Documentation type)"
38+
39+
# ── Triage ───────────────────────────────────────────────────────────────────
40+
# Applied automatically to new issues; removed once a maintainer triages.
41+
42+
- name: "needs-triage"
43+
color: "fbca04"
44+
description: "Awaiting initial triage by a maintainer"
4345

4446
# ── Component ────────────────────────────────────────────────────────────────
45-
# Which part of the project is affected
47+
# Which part of the project is affected. Applied automatically by issue triage
48+
# and PR path labeling. Each component gets a distinct hue so they pop apart at
49+
# a glance; the "component/" prefix keeps them grouped in label lists.
4650

4751
- name: "component/operator"
48-
color: "1d76db"
52+
color: "0969da"
4953
description: "Skyhook operator (controller-manager)"
5054

5155
- name: "component/agent"
52-
color: "1d76db"
56+
color: "1a7f37"
5357
description: "Skyhook agent (package executor)"
5458

5559
- name: "component/chart"
56-
color: "1d76db"
60+
color: "8250df"
5761
description: "Helm chart"
5862

5963
- name: "component/cli"
60-
color: "1d76db"
64+
color: "bc4c00"
6165
description: "kubectl-skyhook CLI plugin"
6266

63-
# ── Planning Types ────────────────────────────────────────────────────────────
64-
# Applied by engineering/product during triage (DGXC OSS Policy issue types)
65-
66-
- name: "epic"
67-
color: "7057ff"
68-
description: "Roadmap feature — large body of work spanning multiple issues"
69-
70-
- name: "feature"
71-
color: "a2eeef"
72-
description: "Goal of a feature request or enhancement (planning label)"
73-
74-
- name: "task"
75-
color: "e4e669"
76-
description: "Sub-task of a feature or epic"
77-
78-
- name: "initiative"
79-
color: "f9d0c4"
80-
description: "Container for a group of related features (optional)"
81-
82-
# ── Priority ─────────────────────────────────────────────────────────────────
83-
# Set by engineering only. SLAs per DGXC OSS Policy:
84-
# P0: major functionality broken, no workaround — 30 day fix SLA
85-
# P1: product works but not as expected, workaround exists — 6 month SLA
86-
# P2: minor defect, minor impact — no fix commitment
87-
88-
- name: "P0"
89-
color: "b60205"
90-
description: "Critical: major functionality broken, no workaround. 30-day SLA."
91-
92-
- name: "P1"
93-
color: "e11d48"
94-
description: "High: product works but not as expected. Workaround exists. 6-month SLA."
67+
- name: "component/ci"
68+
color: "bf3989"
69+
description: "CI workflows, GitHub Actions, and repo tooling"
9570

96-
- name: "P2"
97-
color: "f97316"
98-
description: "Medium: minor defect or minor impact. No fix commitment."
71+
- name: "component/tests"
72+
color: "9a6700"
73+
description: "End-to-end / chainsaw test suites (k8s-tests)"
9974

10075
# ── Lifecycle ─────────────────────────────────────────────────────────────────
10176
# Used by stale automation
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
# SPDX-License-Identifier: Apache-2.0
3+
#
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
name: Inactive PR Reminder
18+
19+
on:
20+
schedule:
21+
- cron: '0 7 * * *' # daily at 07:00 UTC
22+
workflow_dispatch: {}
23+
24+
permissions:
25+
contents: read
26+
27+
concurrency:
28+
group: ${{ github.workflow }}
29+
30+
jobs:
31+
32+
remind:
33+
name: Nudge Inactive PRs
34+
if: github.repository == 'NVIDIA/nodewright'
35+
runs-on: ubuntu-latest
36+
permissions:
37+
pull-requests: write
38+
timeout-minutes: 10
39+
steps:
40+
- name: Check for inactive PRs
41+
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
42+
with:
43+
script: |
44+
const now = new Date();
45+
const msPerDay = 86400000;
46+
const skipLabels = ['lifecycle/frozen', 'do-not-merge'];
47+
48+
const { data: prs } = await github.rest.pulls.list({
49+
owner: context.repo.owner,
50+
repo: context.repo.repo,
51+
state: 'open',
52+
sort: 'updated',
53+
direction: 'asc',
54+
per_page: 100,
55+
});
56+
57+
for (const pr of prs) {
58+
// Skip PRs explicitly held open or parked.
59+
if (pr.labels.some(l => skipLabels.includes(l.name))) continue;
60+
61+
const updated = new Date(pr.updated_at);
62+
const daysInactive = Math.floor((now - updated) / msPerDay);
63+
64+
// Target the 14–29 day window, before the stale bot fires at 30.
65+
if (daysInactive < 14 || daysInactive >= 30) continue;
66+
67+
// Don't double-remind: skip if a bot already left a reminder.
68+
const { data: comments } = await github.rest.issues.listComments({
69+
owner: context.repo.owner,
70+
repo: context.repo.repo,
71+
issue_number: pr.number,
72+
});
73+
const alreadyReminded = comments.some(c =>
74+
c.user.type === 'Bot' && c.body.includes('inactive for')
75+
);
76+
if (alreadyReminded) continue;
77+
78+
await github.rest.issues.createComment({
79+
owner: context.repo.owner,
80+
repo: context.repo.repo,
81+
issue_number: pr.number,
82+
body: `@${pr.user.login} this PR has been inactive for ${daysInactive} days. Do you need help finishing it, or should we close it for now? Feel free to reopen anytime.`,
83+
});
84+
}

0 commit comments

Comments
 (0)