Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 0 additions & 32 deletions .github/workflows/code-butler.yaml

This file was deleted.

3 changes: 1 addition & 2 deletions .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,4 @@ jobs:
close-pr-message: 'This PR was closed because it has been stalled for 7 days with no activity. Feel free to reopen if still applicable.'
days-before-pr-stale: 30
days-before-pr-close: 7
delete-branch: true
exempt-pr-labels: 'not-auto-close'
exempt-pr-labels: 'not-auto-close'
13 changes: 4 additions & 9 deletions .github/workflows/thank-you.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ permissions:

jobs:
thank-you:
# Only run if the PR was actually merged
if: github.event.pull_request.merged
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
# We must check out the code to read the MAINTAINERS.json file
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.sha }}

- name: Leave a Thank You Comment
uses: actions/github-script@v7
Expand All @@ -26,29 +26,24 @@ jobs:
const fs = require('fs');
const creator = context.payload.pull_request.user.login;

// Skip bots to avoid comment loops
if (creator.endsWith('[bot]')) {
console.log('Skipping bot account.');
return;
}

// Read maintainers list from JSON file
const maintainersData = JSON.parse(fs.readFileSync('MAINTAINERS.json', 'utf8'));
const maintainers = maintainersData.maintainers.map(m => m.toLowerCase());

// Skip core maintainers to avoid spamming the team
if (maintainers.includes(creator.toLowerCase())) {
console.log(`Skipping maintainer account: ${creator}`);
return;
}

const message = 'Thank you for contributing to PipeCD! The changes in this pull request will be part of the upcoming release!';
const message = `Thank you for contributing to PipeCD, @${creator}! The changes in this pull request will be part of the upcoming release!`;

// Post the comment to the PR
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.payload.pull_request.number,
body: message
});

2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Documentation
# Documentation XYZ CHANGE FOR TESTING

The source files for the documentation is placing in [content](https://github.com/pipe-cd/pipecd/tree/master/docs/content) directory.

Expand Down
21 changes: 21 additions & 0 deletions workflow-audit/issues/security-code-butler-unpinned-abandoned.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Security: code-butler.yaml uses unpinned third-party action with API key access

**File:** `.github/workflows/code-butler.yaml`

## Problem

`ca-dp/code-butler@v1` is:
- **Not SHA-pinned**: the `v1` mutable tag means any push to the upstream repo moves what this action executes. Anyone who compromises that repo gets code execution in PipeCD CI with access to `OPENAI_API_KEY`.
- **Uses a deprecated model**: `gpt-4-1106-preview` was deprecated by OpenAI in early 2024. The action may already be broken.
- **Third-party, low-visibility**: `ca-dp` is not a well-known GitHub Actions publisher. The action has minimal community scrutiny.

## Impact

- `OPENAI_API_KEY` secret is passed to an unpinned, third-party action.
- `/review` and `/chat` commands on PRs may already be non-functional.

## Recommended Fix

Option A (preferred): Remove the workflow and revoke/rotate `OPENAI_API_KEY`. Check git history for last successful use — if it has not worked since the model was deprecated, it is already dead.

Option B: If AI review is actively used, replace with a custom `actions/github-script` step that calls the API directly (code lives in-repo, no third-party action trust required), and use a current model.