mirror of
https://github.com/anchore/syft.git
synced 2026-03-29 21:23:24 +02:00
remove workflows that update the code
Signed-off-by: Alex Goodman <wagoodman@users.noreply.github.com>
This commit is contained in:
parent
673c85754c
commit
677f4c0110
@ -1,51 +0,0 @@
|
|||||||
name: PR to update Anchore dependencies
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
inputs:
|
|
||||||
repos:
|
|
||||||
description: "List of dependencies to update"
|
|
||||||
required: true
|
|
||||||
type: string
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
update:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: github.repository_owner == 'anchore' # only run for main repo (not forks)
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: Bootstrap environment
|
|
||||||
uses: ./.github/actions/bootstrap
|
|
||||||
with:
|
|
||||||
tools: false
|
|
||||||
bootstrap-apt-packages: ""
|
|
||||||
|
|
||||||
- name: Update dependencies
|
|
||||||
id: update
|
|
||||||
uses: anchore/workflows/.github/actions/update-go-dependencies@main
|
|
||||||
with:
|
|
||||||
repos: ${{ github.event.inputs.repos }}
|
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
|
||||||
id: generate-token
|
|
||||||
with:
|
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
|
||||||
private-key: ${{ secrets.TOKEN_APP_PRIVATE_KEY }}
|
|
||||||
|
|
||||||
- uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 #v8.1.0
|
|
||||||
with:
|
|
||||||
signoff: true
|
|
||||||
delete-branch: true
|
|
||||||
draft: ${{ steps.update.outputs.draft }}
|
|
||||||
# do not change this branch, as other workflows depend on it
|
|
||||||
branch: auto/integration
|
|
||||||
labels: dependencies,pre-release
|
|
||||||
commit-message: "chore(deps): update anchore dependencies"
|
|
||||||
title: "chore(deps): update anchore dependencies"
|
|
||||||
body: ${{ steps.update.outputs.summary }}
|
|
||||||
token: ${{ steps.generate-token.outputs.token }}
|
|
||||||
67
.github/workflows/update-bootstrap-tools.yml
vendored
67
.github/workflows/update-bootstrap-tools.yml
vendored
@ -1,67 +0,0 @@
|
|||||||
name: PR for latest versions of tools
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: "0 8 * * *" # 3 AM EST
|
|
||||||
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
update-bootstrap-tools:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: github.repository == 'anchore/syft' # only run for main repo
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: Bootstrap environment
|
|
||||||
uses: ./.github/actions/bootstrap
|
|
||||||
with:
|
|
||||||
bootstrap-apt-packages: ""
|
|
||||||
go-dependencies: false
|
|
||||||
|
|
||||||
- name: "Update tool versions"
|
|
||||||
id: latest-versions
|
|
||||||
run: |
|
|
||||||
make update-tools
|
|
||||||
make list-tools
|
|
||||||
|
|
||||||
export NO_COLOR=1
|
|
||||||
delimiter="$(openssl rand -hex 8)"
|
|
||||||
|
|
||||||
{
|
|
||||||
echo "status<<${delimiter}"
|
|
||||||
make list-tool-updates
|
|
||||||
echo "${delimiter}"
|
|
||||||
} >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
{
|
|
||||||
echo "### Tool version status"
|
|
||||||
echo "\`\`\`"
|
|
||||||
make list-tool-updates
|
|
||||||
echo "\`\`\`"
|
|
||||||
} >> $GITHUB_STEP_SUMMARY
|
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
|
||||||
id: generate-token
|
|
||||||
with:
|
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
|
||||||
private-key: ${{ secrets.TOKEN_APP_PRIVATE_KEY }}
|
|
||||||
|
|
||||||
- uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 #v8.1.0
|
|
||||||
with:
|
|
||||||
signoff: true
|
|
||||||
delete-branch: true
|
|
||||||
branch: auto/latest-tools
|
|
||||||
labels: dependencies
|
|
||||||
commit-message: 'chore(deps): update tools to latest versions'
|
|
||||||
title: 'chore(deps): update tools to latest versions'
|
|
||||||
body: |
|
|
||||||
```
|
|
||||||
${{ steps.latest-versions.outputs.status }}
|
|
||||||
```
|
|
||||||
This is an auto-generated pull request to update all of the tools to the latest versions.
|
|
||||||
token: ${{ steps.generate-token.outputs.token }}
|
|
||||||
@ -1,84 +0,0 @@
|
|||||||
name: PR to update CPE dictionary index
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: "0 1 * * 1" # every monday at 1 AM
|
|
||||||
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
env:
|
|
||||||
SLACK_NOTIFICATIONS: true
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
upgrade-cpe-dictionary-index:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
packages: write
|
|
||||||
if: github.repository == 'anchore/syft' # only run for main repo
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: Bootstrap environment
|
|
||||||
uses: ./.github/actions/bootstrap
|
|
||||||
id: bootstrap
|
|
||||||
|
|
||||||
- name: Login to GitHub Container Registry
|
|
||||||
run: echo "${{ secrets.GITHUB_TOKEN }}" | .tool/oras login ghcr.io -u "$ACTOR" --password-stdin
|
|
||||||
env:
|
|
||||||
ACTOR: ${{ github.actor }}
|
|
||||||
|
|
||||||
- name: Pull CPE cache from registry
|
|
||||||
run: make generate:cpe-index:cache:pull
|
|
||||||
|
|
||||||
- name: Update CPE cache from NVD API
|
|
||||||
run: make generate:cpe-index:cache:update
|
|
||||||
env:
|
|
||||||
NVD_API_KEY: ${{ secrets.NVD_API_KEY }}
|
|
||||||
|
|
||||||
- name: Generate CPE dictionary index
|
|
||||||
run: make generate:cpe-index:build
|
|
||||||
|
|
||||||
- name: Push updated CPE cache to registry
|
|
||||||
run: make generate:cpe-index:cache:push
|
|
||||||
|
|
||||||
- uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf #v2.2.1
|
|
||||||
id: generate-token
|
|
||||||
with:
|
|
||||||
app-id: ${{ secrets.TOKEN_APP_ID }}
|
|
||||||
private-key: ${{ secrets.TOKEN_APP_PRIVATE_KEY }}
|
|
||||||
|
|
||||||
- uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 #v8.1.0
|
|
||||||
with:
|
|
||||||
signoff: true
|
|
||||||
delete-branch: true
|
|
||||||
branch: auto/latest-cpe-dictionary-index
|
|
||||||
labels: dependencies
|
|
||||||
commit-message: "chore(deps): update CPE dictionary index"
|
|
||||||
title: "chore(deps): update CPE dictionary index"
|
|
||||||
body: |
|
|
||||||
Update CPE dictionary index based on the latest available CPE dictionary
|
|
||||||
token: ${{ steps.generate-token.outputs.token }}
|
|
||||||
|
|
||||||
- name: Notify Slack on failure
|
|
||||||
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a #v2.1.1
|
|
||||||
with:
|
|
||||||
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
|
||||||
webhook-type: incoming-webhook
|
|
||||||
payload: |
|
|
||||||
text: "Syft CPE dictionary index update failed"
|
|
||||||
blocks:
|
|
||||||
- type: section
|
|
||||||
text:
|
|
||||||
type: mrkdwn
|
|
||||||
text: |
|
|
||||||
*Syft CPE dictionary index update failed*
|
|
||||||
• Workflow: `${{ github.workflow }}`
|
|
||||||
• Event: `${{ github.event_name }}`
|
|
||||||
• Job Status: `${{ job.status }}`
|
|
||||||
• <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run>
|
|
||||||
if: ${{ failure() && env.SLACK_NOTIFICATIONS == 'true' }}
|
|
||||||
64
.github/workflows/update-spdx-license-list.yaml
vendored
64
.github/workflows/update-spdx-license-list.yaml
vendored
@ -1,64 +0,0 @@
|
|||||||
name: PR to update SPDX license list
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: "0 6 * * 1" # every monday at 6 AM UTC
|
|
||||||
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
env:
|
|
||||||
SLACK_NOTIFICATIONS: true
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
upgrade-spdx-license-list:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: github.repository == 'anchore/syft' # only run for main repo
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: Bootstrap environment
|
|
||||||
uses: ./.github/actions/bootstrap
|
|
||||||
|
|
||||||
- run: |
|
|
||||||
make generate-license-list
|
|
||||||
|
|
||||||
- uses: tibdex/github-app-token@3beb63f4bd073e61482598c45c71c1019b59b73a #v2.1.0
|
|
||||||
id: generate-token
|
|
||||||
with:
|
|
||||||
app_id: ${{ secrets.TOKEN_APP_ID }}
|
|
||||||
private_key: ${{ secrets.TOKEN_APP_PRIVATE_KEY }}
|
|
||||||
|
|
||||||
- uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 #v8.1.0
|
|
||||||
with:
|
|
||||||
signoff: true
|
|
||||||
delete-branch: true
|
|
||||||
branch: auto/latest-spdx-license-list
|
|
||||||
labels: dependencies
|
|
||||||
commit-message: "chore(deps): update SPDX license list"
|
|
||||||
title: "chore(deps): update SPDX license list"
|
|
||||||
body: |
|
|
||||||
Update SPDX license list based on the latest available list from spdx.org
|
|
||||||
token: ${{ steps.generate-token.outputs.token }}
|
|
||||||
|
|
||||||
- name: Notify Slack on failure
|
|
||||||
uses: slackapi/slack-github-action@91efab103c0de0a537f72a35f6b8cda0ee76bf0a #v2.1.1
|
|
||||||
with:
|
|
||||||
webhook: ${{ secrets.SLACK_TOOLBOX_WEBHOOK_URL }}
|
|
||||||
webhook-type: incoming-webhook
|
|
||||||
payload: |
|
|
||||||
text: "Syft SPDX license list update failed"
|
|
||||||
blocks:
|
|
||||||
- type: section
|
|
||||||
text:
|
|
||||||
type: mrkdwn
|
|
||||||
text: |
|
|
||||||
*Syft SPDX license list update failed*
|
|
||||||
• Workflow: `${{ github.workflow }}`
|
|
||||||
• Event: `${{ github.event_name }}`
|
|
||||||
• Job Status: `${{ job.status }}`
|
|
||||||
• <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run>
|
|
||||||
if: ${{ failure() && env.SLACK_NOTIFICATIONS == 'true' }}
|
|
||||||
Loading…
x
Reference in New Issue
Block a user