-
Notifications
You must be signed in to change notification settings - Fork 28
77 lines (68 loc) · 2.24 KB
/
template-sync.yaml
File metadata and controls
77 lines (68 loc) · 2.24 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
---
name: Template Sync
on:
# checkov:skip=CKV_GHA_7: "Workflow dispatch inputs are required for manual debugging and configuration"
workflow_dispatch:
inputs:
dryRun:
description: Dry Run
default: "false"
required: false
logLevel:
description: Log Level
default: "debug"
required: false
schedule:
# Run on the 1st of every month at 00:00 UTC
- cron: "0 0 1 * *"
push:
branches: ["main"]
paths:
- ".github/**"
- ".hooks/**"
- ".pre-commit-config.yaml"
- ".mdlrc"
- ".editorconfig"
- "Taskfile.yaml"
- ".task/**"
permissions:
contents: write
pull-requests: write
concurrency:
group: ${{ github.workflow }}-${{ github.run_number || github.ref }}
cancel-in-progress: true
jobs:
template-sync:
name: Template Sync
runs-on: ubuntu-latest
steps:
- name: Generate Token
uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2.2.1
id: app-token
with:
app-id: "${{ secrets.BOT_APP_ID }}"
private-key: "${{ secrets.BOT_APP_PRIVATE_KEY }}"
owner: "${{ github.repository_owner }}"
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
token: "${{ steps.app-token.outputs.token }}"
- name: Template Sync
uses: AndreasAugustin/actions-template-sync@v2
with:
source_gh_token: ${{ steps.app-token.outputs.token }}
git_user_name: github-actions[bot]
git_user_email: github-actions[bot]@users.noreply.github.com
pr_title: "chore: sync infrastructure files with template"
pr_labels: sync,template
pr_body: |
🤖 A new version of the python template files is available.
This PR was automatically created to sync the following:
- GitHub Actions workflows
- Pre-commit hooks and configs
- Task definitions
- Editor configs and linter rules
Please review the changes carefully before merging.
source_repo_path: dreadnode/python-template
steps: "prechecks,pull,commit,push,pr"
upstream_branch: main