@hybridlabor-api/aos 4.7.2 → 4.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/agents.md +1 -1
- package/.agents/nodes.json +1 -1
- package/.agents/vendor-manifest.json +23 -1
- package/.claude/agents/godmode-media-eventtech.md +1 -1
- package/.claude/hooks/conventional-commits.mjs +125 -0
- package/.claude/hooks/env-file-protection.mjs +105 -0
- package/.claude/hooks/go-gate.mjs +101 -81
- package/.claude/settings.json +13 -0
- package/.opencode/agents/godmode-media-eventtech.md +1 -1
- package/.opencode/plugins/bdb-aos.js +31 -4
- package/README.de.md +1 -1
- package/README.md +1 -1
- package/README.pt.md +1 -1
- package/THIRD_PARTY_NOTICES.md +88 -0
- package/docs/skills_table.md +1 -1
- package/installer.js +309 -101
- package/package.json +6 -2
- package/packages/aos-cli/README.md +80 -0
- package/packages/aos-cli/bin/aos-cli.mjs +134 -0
- package/packages/aos-cli/core-skills.json +12 -0
- package/packages/aos-cli/extensions/aos.ts +321 -0
- package/packages/aos-cli/package-lock.json +1923 -0
- package/packages/aos-cli/package.json +29 -0
- package/packages/aos-cli/scripts/check-theme.mjs +63 -0
- package/packages/aos-cli/themes/aos.json +97 -0
- package/scripts/build-plugin-manifest.mjs +131 -0
- package/scripts/validate-skills.mjs +81 -6
- package/skills/basic/ao-orchestrator/SKILL.md +116 -0
- package/skills/global_config/agenttrail/SKILL.md +6 -1
- package/skills/global_config/ask-tim/SKILL.md +4 -4
- package/skills/global_config/bash-script-generator/SKILL.md +201 -0
- package/skills/global_config/bash-script-generator/assets/templates/standard-template.sh +96 -0
- package/skills/global_config/bash-script-generator/docs/bash-scripting-guide.md +729 -0
- package/skills/global_config/bash-script-generator/docs/generation-best-practices.md +193 -0
- package/skills/global_config/bash-script-generator/docs/script-patterns.md +566 -0
- package/skills/global_config/bash-script-generator/docs/text-processing-guide.md +437 -0
- package/skills/global_config/bash-script-generator/examples/log-analyzer.sh +92 -0
- package/skills/global_config/bash-script-generator/scripts/generate_script_template.sh +123 -0
- package/skills/global_config/bash-script-generator/scripts/run_ci_checks.sh +172 -0
- package/skills/global_config/bash-script-generator/scripts/test_generator.sh +413 -0
- package/skills/global_config/bash-script-validator/SKILL.md +249 -0
- package/skills/global_config/bash-script-validator/docs/awk-reference.md +449 -0
- package/skills/global_config/bash-script-validator/docs/bash-reference.md +468 -0
- package/skills/global_config/bash-script-validator/docs/common-mistakes.md +623 -0
- package/skills/global_config/bash-script-validator/docs/grep-reference.md +395 -0
- package/skills/global_config/bash-script-validator/docs/regex-reference.md +391 -0
- package/skills/global_config/bash-script-validator/docs/sed-reference.md +454 -0
- package/skills/global_config/bash-script-validator/docs/shell-reference.md +463 -0
- package/skills/global_config/bash-script-validator/docs/shellcheck-reference.md +399 -0
- package/skills/global_config/bash-script-validator/examples/bad-bash.sh +55 -0
- package/skills/global_config/bash-script-validator/examples/bad-shell.sh +54 -0
- package/skills/global_config/bash-script-validator/examples/good-bash.sh +71 -0
- package/skills/global_config/bash-script-validator/examples/good-shell.sh +69 -0
- package/skills/global_config/bash-script-validator/scripts/run_ci_checks.sh +23 -0
- package/skills/global_config/bash-script-validator/scripts/shellcheck_wrapper.sh +174 -0
- package/skills/global_config/bash-script-validator/scripts/test_validate.sh +446 -0
- package/skills/global_config/bash-script-validator/scripts/validate.sh +512 -0
- package/skills/global_config/ci-pipeline/SKILL.md +135 -0
- package/skills/global_config/dispatching-parallel-agents/SKILL.md +170 -0
- package/skills/global_config/dockerfile-generator/SKILL.md +1038 -0
- package/skills/global_config/dockerfile-generator/examples/example.dockerignore +95 -0
- package/skills/global_config/dockerfile-generator/examples/golang-distroless.Dockerfile +34 -0
- package/skills/global_config/dockerfile-generator/examples/java-springboot.Dockerfile +45 -0
- package/skills/global_config/dockerfile-generator/examples/nextjs-production.Dockerfile +49 -0
- package/skills/global_config/dockerfile-generator/examples/nodejs-multistage.Dockerfile +55 -0
- package/skills/global_config/dockerfile-generator/examples/python-fastapi.Dockerfile +48 -0
- package/skills/global_config/dockerfile-generator/references/language_specific_guides.md +510 -0
- package/skills/global_config/dockerfile-generator/references/multistage_builds.md +570 -0
- package/skills/global_config/dockerfile-generator/references/optimization_patterns.md +492 -0
- package/skills/global_config/dockerfile-generator/references/security_best_practices.md +375 -0
- package/skills/global_config/dockerfile-generator/scripts/generate_dockerignore.sh +199 -0
- package/skills/global_config/dockerfile-generator/scripts/generate_golang.sh +172 -0
- package/skills/global_config/dockerfile-generator/scripts/generate_java.sh +185 -0
- package/skills/global_config/dockerfile-generator/scripts/generate_nodejs.sh +279 -0
- package/skills/global_config/dockerfile-generator/scripts/generate_python.sh +218 -0
- package/skills/global_config/dockerfile-generator/scripts/test_generator.sh +210 -0
- package/skills/global_config/dockerfile-validator/SKILL.md +300 -0
- package/skills/global_config/dockerfile-validator/examples/.dockerignore.example +34 -0
- package/skills/global_config/dockerfile-validator/examples/bad-example.Dockerfile +37 -0
- package/skills/global_config/dockerfile-validator/examples/golang-distroless.Dockerfile +50 -0
- package/skills/global_config/dockerfile-validator/examples/good-example.Dockerfile +52 -0
- package/skills/global_config/dockerfile-validator/examples/python-optimized.Dockerfile +53 -0
- package/skills/global_config/dockerfile-validator/examples/security-issues.Dockerfile +42 -0
- package/skills/global_config/dockerfile-validator/references/docker_best_practices.md +348 -0
- package/skills/global_config/dockerfile-validator/references/optimization_guide.md +473 -0
- package/skills/global_config/dockerfile-validator/references/security_checklist.md +208 -0
- package/skills/global_config/dockerfile-validator/scripts/dockerfile-validate.sh +699 -0
- package/skills/global_config/dockerfile-validator/scripts/test_validate.sh +35 -0
- package/skills/global_config/dockerfile-validator/tests/fixtures/copy-before-yarn-lock-read.Dockerfile +6 -0
- package/skills/global_config/dockerfile-validator/tests/fixtures/copy-before-yarn.Dockerfile +6 -0
- package/skills/global_config/dockerfile-validator/tests/fixtures/from-platform-nonroot.Dockerfile +7 -0
- package/skills/global_config/dockerfile-validator/tests/test_regression.sh +164 -0
- package/skills/global_config/finishing-a-development-branch/SKILL.md +228 -0
- package/skills/global_config/github-actions-generator/SKILL.md +353 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/composite/action.yml +82 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/docker/Dockerfile +25 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/docker/action.yml +42 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/docker/entrypoint.sh +27 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/javascript/action.yml +33 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/javascript/index.js +50 -0
- package/skills/global_config/github-actions-generator/assets/templates/action/javascript/package.json +27 -0
- package/skills/global_config/github-actions-generator/assets/templates/workflow/basic_workflow.yml +242 -0
- package/skills/global_config/github-actions-generator/assets/templates/workflow/reusable_workflow.yml +106 -0
- package/skills/global_config/github-actions-generator/examples/README.md +147 -0
- package/skills/global_config/github-actions-generator/examples/actions/setup-node-cached/action.yml +93 -0
- package/skills/global_config/github-actions-generator/examples/caching/docker-buildkit.yml +256 -0
- package/skills/global_config/github-actions-generator/examples/security/dependency-review.yml +62 -0
- package/skills/global_config/github-actions-generator/examples/security/sbom-attestation.yml +119 -0
- package/skills/global_config/github-actions-generator/examples/triggers/chatops-commands.yml +475 -0
- package/skills/global_config/github-actions-generator/examples/triggers/repository-dispatch.yml +418 -0
- package/skills/global_config/github-actions-generator/examples/triggers/workflow-orchestration.yml +404 -0
- package/skills/global_config/github-actions-generator/examples/workflows/docker-build-push.yml +68 -0
- package/skills/global_config/github-actions-generator/examples/workflows/go-ci.yml +161 -0
- package/skills/global_config/github-actions-generator/examples/workflows/monorepo-ci.yml +340 -0
- package/skills/global_config/github-actions-generator/examples/workflows/multi-environment-deploy.yml +406 -0
- package/skills/global_config/github-actions-generator/examples/workflows/nodejs-ci.yml +122 -0
- package/skills/global_config/github-actions-generator/examples/workflows/python-ci.yml +157 -0
- package/skills/global_config/github-actions-generator/examples/workflows/scheduled-tasks.yml +376 -0
- package/skills/global_config/github-actions-generator/references/advanced-triggers.md +917 -0
- package/skills/global_config/github-actions-generator/references/best-practices.md +755 -0
- package/skills/global_config/github-actions-generator/references/common-actions.md +715 -0
- package/skills/global_config/github-actions-generator/references/custom-actions.md +320 -0
- package/skills/global_config/github-actions-generator/references/expressions-and-contexts.md +688 -0
- package/skills/global_config/github-actions-generator/references/modern-features.md +421 -0
- package/skills/global_config/github-actions-generator/scripts/test_generator.sh +344 -0
- package/skills/global_config/github-actions-templates/SKILL.md +7 -0
- package/skills/global_config/github-actions-validator/SKILL.md +576 -0
- package/skills/global_config/github-actions-validator/examples/README.md +88 -0
- package/skills/global_config/github-actions-validator/examples/outdated-versions.yml +76 -0
- package/skills/global_config/github-actions-validator/examples/valid-ci.yml +79 -0
- package/skills/global_config/github-actions-validator/examples/with-errors.yml +47 -0
- package/skills/global_config/github-actions-validator/references/act_usage.md +233 -0
- package/skills/global_config/github-actions-validator/references/action_versions.md +122 -0
- package/skills/global_config/github-actions-validator/references/actionlint_usage.md +343 -0
- package/skills/global_config/github-actions-validator/references/common_errors.md +512 -0
- package/skills/global_config/github-actions-validator/references/modern_features.md +384 -0
- package/skills/global_config/github-actions-validator/references/runners.md +317 -0
- package/skills/global_config/github-actions-validator/scripts/install_tools.sh +113 -0
- package/skills/global_config/github-actions-validator/scripts/validate_workflow.sh +910 -0
- package/skills/global_config/github-actions-validator/tests/test_validate_workflow.sh +237 -0
- package/skills/global_config/makefile-generator/SKILL.md +614 -0
- package/skills/global_config/makefile-generator/assets/templates/.gitkeep +1 -0
- package/skills/global_config/makefile-generator/docs/makefile-structure.md +530 -0
- package/skills/global_config/makefile-generator/docs/optimization-guide.md +784 -0
- package/skills/global_config/makefile-generator/docs/patterns-guide.md +642 -0
- package/skills/global_config/makefile-generator/docs/security-guide.md +361 -0
- package/skills/global_config/makefile-generator/docs/targets-guide.md +642 -0
- package/skills/global_config/makefile-generator/docs/variables-guide.md +596 -0
- package/skills/global_config/makefile-generator/scripts/add_standard_targets.sh +539 -0
- package/skills/global_config/makefile-generator/scripts/generate_makefile_template.sh +690 -0
- package/skills/global_config/makefile-generator/test/test_helper_scripts.sh +190 -0
- package/skills/global_config/makefile-validator/SKILL.md +244 -0
- package/skills/global_config/makefile-validator/docs/bake-tool.md +1000 -0
- package/skills/global_config/makefile-validator/docs/best-practices.md +858 -0
- package/skills/global_config/makefile-validator/docs/common-mistakes.md +944 -0
- package/skills/global_config/makefile-validator/examples/bad-makefile.mk +77 -0
- package/skills/global_config/makefile-validator/examples/good-makefile.mk +103 -0
- package/skills/global_config/makefile-validator/scripts/test_validate.sh +382 -0
- package/skills/global_config/makefile-validator/scripts/validate_makefile.sh +712 -0
- package/skills/global_config/{MCP_Manage → mcp-manage}/SKILL.md +3 -3
- package/skills/global_config/requesting-code-review/SKILL.md +98 -0
- package/skills/global_config/requesting-code-review/code-reviewer.md +198 -0
- package/skills/global_config/using-git-worktrees/SKILL.md +170 -0
- package/skills/global_config/verification-before-completion/SKILL.md +123 -0
- package/skills/global_config/writing-plans/SKILL.md +126 -46
- package/skills/global_config/writing-plans-legacy/SKILL.md +139 -0
|
@@ -0,0 +1,715 @@
|
|
|
1
|
+
# Common GitHub Actions Reference
|
|
2
|
+
|
|
3
|
+
**Last Updated:** February 2026
|
|
4
|
+
**Source:** Official GitHub Actions repositories and Context7 verified documentation
|
|
5
|
+
|
|
6
|
+
This document catalogs frequently used GitHub Actions with current versions, inputs, outputs, and usage examples.
|
|
7
|
+
|
|
8
|
+
**Important Notes for 2026:**
|
|
9
|
+
- All actions should be pinned to full 40-character SHA for security
|
|
10
|
+
- Node 24 runtime is now supported (Node 20 EOL: April 2026, default switch: March 4, 2026)
|
|
11
|
+
- actions/cache v5.0.3 recommended (Node 24 runtime, runner v2.327.1+)
|
|
12
|
+
- Cache size limits: 10 GB free per repository, additional storage available (as of February 2026)
|
|
13
|
+
|
|
14
|
+
## Table of Contents
|
|
15
|
+
1. [Repository and Checkout](#repository-and-checkout)
|
|
16
|
+
2. [Language and Tool Setup](#language-and-tool-setup)
|
|
17
|
+
3. [Caching](#caching)
|
|
18
|
+
4. [Artifacts](#artifacts)
|
|
19
|
+
5. [Docker](#docker)
|
|
20
|
+
6. [Cloud Providers](#cloud-providers)
|
|
21
|
+
7. [Testing and Code Quality](#testing-and-code-quality)
|
|
22
|
+
8. [Notifications](#notifications)
|
|
23
|
+
9. [Release and Publishing](#release-and-publishing)
|
|
24
|
+
10. [Security](#security)
|
|
25
|
+
|
|
26
|
+
## Repository and Checkout
|
|
27
|
+
|
|
28
|
+
### actions/checkout
|
|
29
|
+
|
|
30
|
+
**Latest Version:** v6 (v6.0.2)
|
|
31
|
+
**SHA:** `de0fac2e4500dabe0009e67214ff5f5447ce83dd`
|
|
32
|
+
**Minimum Runner:** v2.327.1+
|
|
33
|
+
|
|
34
|
+
**Description:** Checkout repository code with improved performance, tag handling, and security
|
|
35
|
+
|
|
36
|
+
**Common Inputs:**
|
|
37
|
+
- `fetch-depth`: Number of commits to fetch (default: 1, use 0 for full history)
|
|
38
|
+
- `ref`: Branch, tag, or SHA to checkout
|
|
39
|
+
- `token`: PAT for private repos (default: `${{ github.token }}`)
|
|
40
|
+
- `submodules`: Whether to checkout submodules (`false`, `true`, `recursive`)
|
|
41
|
+
- `lfs`: Whether to download Git LFS files (default: `false`)
|
|
42
|
+
- `sparse-checkout`: Paths to checkout (cone mode or individual files) - **Available in v5+**
|
|
43
|
+
- `sparse-checkout-cone-mode`: Use cone mode for sparse checkout (default: `true`)
|
|
44
|
+
|
|
45
|
+
**Required Permissions:**
|
|
46
|
+
```yaml
|
|
47
|
+
permissions:
|
|
48
|
+
contents: read
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
**Examples:**
|
|
52
|
+
|
|
53
|
+
**Basic checkout:**
|
|
54
|
+
```yaml
|
|
55
|
+
- name: Checkout code
|
|
56
|
+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
57
|
+
with:
|
|
58
|
+
fetch-depth: 1
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
**Full history (for changelog/tags):**
|
|
62
|
+
```yaml
|
|
63
|
+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
64
|
+
with:
|
|
65
|
+
fetch-depth: 0
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
**Sparse checkout (specific directories):**
|
|
69
|
+
```yaml
|
|
70
|
+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
71
|
+
with:
|
|
72
|
+
sparse-checkout: |
|
|
73
|
+
.github
|
|
74
|
+
src
|
|
75
|
+
tests
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
**Checkout PR HEAD commit:**
|
|
79
|
+
```yaml
|
|
80
|
+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
81
|
+
with:
|
|
82
|
+
ref: ${{ github.event.pull_request.head.sha }}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
**Checkout private repository:**
|
|
86
|
+
```yaml
|
|
87
|
+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
88
|
+
with:
|
|
89
|
+
repository: my-org/my-private-repo
|
|
90
|
+
token: ${{ secrets.GH_PAT }}
|
|
91
|
+
path: my-repo
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
## Language and Tool Setup
|
|
95
|
+
|
|
96
|
+
### actions/setup-node
|
|
97
|
+
|
|
98
|
+
**Latest Version:** v6 (v6.2.0)
|
|
99
|
+
**SHA:** `6044e13b5dc448c55e2357c09f80417699197238`
|
|
100
|
+
**Minimum Runner:** v2.328.0+ (for Node 24 support)
|
|
101
|
+
|
|
102
|
+
**Description:** Setup Node.js environment with Node 24 support
|
|
103
|
+
|
|
104
|
+
**Important:** Node 24 runtime is now supported. Node 20 deprecation timeline: Default switch March 4, 2026 → EOL April 2026 → Complete removal Summer 2026.
|
|
105
|
+
|
|
106
|
+
**Common Inputs:**
|
|
107
|
+
- `node-version`: Version to use (e.g., `'24'`, `'20'`, `'18.x'`, `'lts/*'`)
|
|
108
|
+
- `cache`: Package manager to cache (`'npm'`, `'yarn'`, `'pnpm'`)
|
|
109
|
+
- `cache-dependency-path`: Path to lock file(s)
|
|
110
|
+
- `registry-url`: NPM registry URL for publishing
|
|
111
|
+
- `always-auth`: Set always-auth in npmrc (default: `false`)
|
|
112
|
+
|
|
113
|
+
**Examples:**
|
|
114
|
+
|
|
115
|
+
**Basic setup with caching:**
|
|
116
|
+
```yaml
|
|
117
|
+
- name: Setup Node.js 24
|
|
118
|
+
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
|
119
|
+
with:
|
|
120
|
+
node-version: '24'
|
|
121
|
+
cache: 'npm'
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
**Multi-lock-file caching:**
|
|
125
|
+
```yaml
|
|
126
|
+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
|
127
|
+
with:
|
|
128
|
+
node-version: '24'
|
|
129
|
+
cache: 'npm'
|
|
130
|
+
cache-dependency-path: |
|
|
131
|
+
package-lock.json
|
|
132
|
+
packages/*/package-lock.json
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
**Setup for package publishing:**
|
|
136
|
+
```yaml
|
|
137
|
+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
|
138
|
+
with:
|
|
139
|
+
node-version: '20'
|
|
140
|
+
registry-url: 'https://registry.npmjs.org'
|
|
141
|
+
|
|
142
|
+
- run: npm publish
|
|
143
|
+
env:
|
|
144
|
+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
### actions/setup-python
|
|
148
|
+
|
|
149
|
+
**Latest Version:** v6 (v6.2.0)
|
|
150
|
+
**SHA:** `a309ff8b426b58ec0e2a45f0f869d46889d02405`
|
|
151
|
+
|
|
152
|
+
**Description:** Setup Python environment
|
|
153
|
+
|
|
154
|
+
**Common Inputs:**
|
|
155
|
+
- `python-version`: Version to use (e.g., `'3.11'`, `'3.x'`)
|
|
156
|
+
- `cache`: Package manager to cache (`'pip'`, `'pipenv'`, `'poetry'`)
|
|
157
|
+
- `cache-dependency-path`: Path to requirements file
|
|
158
|
+
|
|
159
|
+
**Example:**
|
|
160
|
+
```yaml
|
|
161
|
+
- name: Setup Python
|
|
162
|
+
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
|
|
163
|
+
with:
|
|
164
|
+
python-version: '3.11'
|
|
165
|
+
cache: 'pip'
|
|
166
|
+
cache-dependency-path: 'requirements*.txt'
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
### actions/setup-java
|
|
170
|
+
|
|
171
|
+
**Latest Version:** v4 (v4.0.0)
|
|
172
|
+
**SHA:** `387ac29b308b003ca37ba93a6cab5eb57c8f5f93`
|
|
173
|
+
|
|
174
|
+
**Description:** Setup Java environment
|
|
175
|
+
|
|
176
|
+
**Common Inputs:**
|
|
177
|
+
- `distribution`: Java distribution (`'temurin'`, `'zulu'`, `'adopt'`, etc.)
|
|
178
|
+
- `java-version`: Version to use (e.g., `'17'`, `'11'`)
|
|
179
|
+
- `cache`: Build tool to cache (`'maven'`, `'gradle'`, `'sbt'`)
|
|
180
|
+
|
|
181
|
+
**Example:**
|
|
182
|
+
```yaml
|
|
183
|
+
- name: Setup Java
|
|
184
|
+
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 # v4.0.0
|
|
185
|
+
with:
|
|
186
|
+
distribution: 'temurin'
|
|
187
|
+
java-version: '17'
|
|
188
|
+
cache: 'maven'
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
### actions/setup-go
|
|
192
|
+
|
|
193
|
+
**Latest Version:** v5 (v5.0.0)
|
|
194
|
+
**SHA:** `0c52d547c9bc32b1aa3301fd7a9cb496313a4491`
|
|
195
|
+
|
|
196
|
+
**Description:** Setup Go environment
|
|
197
|
+
|
|
198
|
+
**Common Inputs:**
|
|
199
|
+
- `go-version`: Version to use (e.g., `'1.21'`, `'stable'`)
|
|
200
|
+
- `cache`: Whether to cache dependencies (default: `true`)
|
|
201
|
+
- `cache-dependency-path`: Path to go.sum
|
|
202
|
+
|
|
203
|
+
**Example:**
|
|
204
|
+
```yaml
|
|
205
|
+
- name: Setup Go
|
|
206
|
+
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
|
|
207
|
+
with:
|
|
208
|
+
go-version: '1.21'
|
|
209
|
+
cache-dependency-path: go.sum
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
## Caching
|
|
213
|
+
|
|
214
|
+
### actions/cache
|
|
215
|
+
|
|
216
|
+
**Latest Version:** v5 (v5.0.3)
|
|
217
|
+
**SHA:** `cdf6c1fa76f9f475f3d7449005a359c84ca0f306`
|
|
218
|
+
|
|
219
|
+
**Description:** Cache dependencies and build outputs with Node 24 runtime support
|
|
220
|
+
|
|
221
|
+
**Important:** actions/cache v5 requires GitHub Actions runner v2.327.1 or later. Repositories get 10 GB free cache storage, with additional storage available.
|
|
222
|
+
|
|
223
|
+
**Required Inputs:**
|
|
224
|
+
- `path`: Directories to cache
|
|
225
|
+
- `key`: Cache key (must be unique)
|
|
226
|
+
|
|
227
|
+
**Optional Inputs:**
|
|
228
|
+
- `restore-keys`: Fallback keys if exact key not found
|
|
229
|
+
|
|
230
|
+
**Example:**
|
|
231
|
+
```yaml
|
|
232
|
+
- name: Cache dependencies
|
|
233
|
+
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
|
|
234
|
+
with:
|
|
235
|
+
path: |
|
|
236
|
+
~/.npm
|
|
237
|
+
~/.cache
|
|
238
|
+
node_modules
|
|
239
|
+
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
|
|
240
|
+
restore-keys: |
|
|
241
|
+
${{ runner.os }}-node-
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
## Artifacts
|
|
245
|
+
|
|
246
|
+
### actions/upload-artifact
|
|
247
|
+
|
|
248
|
+
**Latest Version:** v4 (v4.3.1)
|
|
249
|
+
**SHA:** `5d5d22a31266ced268874388b861e4b58bb5c2f3`
|
|
250
|
+
|
|
251
|
+
**Description:** Upload build artifacts
|
|
252
|
+
|
|
253
|
+
**Required Inputs:**
|
|
254
|
+
- `name`: Artifact name
|
|
255
|
+
- `path`: Files to upload
|
|
256
|
+
|
|
257
|
+
**Optional Inputs:**
|
|
258
|
+
- `retention-days`: How long to keep artifact (1-90, default: 90)
|
|
259
|
+
- `if-no-files-found`: What to do if no files found (`warn`, `error`, `ignore`)
|
|
260
|
+
|
|
261
|
+
**Example:**
|
|
262
|
+
```yaml
|
|
263
|
+
- name: Upload build artifacts
|
|
264
|
+
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
|
|
265
|
+
with:
|
|
266
|
+
name: build-${{ github.sha }}
|
|
267
|
+
path: dist/
|
|
268
|
+
retention-days: 7
|
|
269
|
+
if-no-files-found: error
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
### actions/download-artifact
|
|
273
|
+
|
|
274
|
+
**Latest Version:** v4 (v4.1.4)
|
|
275
|
+
**SHA:** `c850b930e6ba138125429b7e5c93fc707a7f8427`
|
|
276
|
+
|
|
277
|
+
**Description:** Download artifacts from previous jobs
|
|
278
|
+
|
|
279
|
+
**Optional Inputs:**
|
|
280
|
+
- `name`: Artifact name (downloads all if not specified)
|
|
281
|
+
- `path`: Destination path
|
|
282
|
+
|
|
283
|
+
**Example:**
|
|
284
|
+
```yaml
|
|
285
|
+
- name: Download build artifacts
|
|
286
|
+
uses: actions/download-artifact@c850b930e6ba138125429b7e5c93fc707a7f8427 # v4.1.4
|
|
287
|
+
with:
|
|
288
|
+
name: build-${{ github.sha }}
|
|
289
|
+
path: dist/
|
|
290
|
+
```
|
|
291
|
+
|
|
292
|
+
## Docker
|
|
293
|
+
|
|
294
|
+
### docker/setup-buildx-action
|
|
295
|
+
|
|
296
|
+
**Latest Version:** v3 (v3.3.0)
|
|
297
|
+
**SHA:** `d70bba72b1f3fd22344832f00baa16ece964efeb`
|
|
298
|
+
|
|
299
|
+
**Description:** Setup Docker Buildx for advanced builds
|
|
300
|
+
|
|
301
|
+
**Example:**
|
|
302
|
+
```yaml
|
|
303
|
+
- name: Set up Docker Buildx
|
|
304
|
+
uses: docker/setup-buildx-action@d70bba72b1f3fd22344832f00baa16ece964efeb # v3.3.0
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
### docker/login-action
|
|
308
|
+
|
|
309
|
+
**Latest Version:** v3 (v3.1.0)
|
|
310
|
+
**SHA:** `e92390c5fb421da1463c202d546fed0ec5c39f20`
|
|
311
|
+
|
|
312
|
+
**Description:** Login to Docker registry
|
|
313
|
+
|
|
314
|
+
**Common Inputs:**
|
|
315
|
+
- `registry`: Registry to login to (default: Docker Hub)
|
|
316
|
+
- `username`: Username
|
|
317
|
+
- `password`: Password or token
|
|
318
|
+
|
|
319
|
+
**Example:**
|
|
320
|
+
```yaml
|
|
321
|
+
# Docker Hub
|
|
322
|
+
- name: Login to Docker Hub
|
|
323
|
+
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 # v3.1.0
|
|
324
|
+
with:
|
|
325
|
+
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
326
|
+
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
327
|
+
|
|
328
|
+
# GitHub Container Registry
|
|
329
|
+
- name: Login to GHCR
|
|
330
|
+
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 # v3.1.0
|
|
331
|
+
with:
|
|
332
|
+
registry: ghcr.io
|
|
333
|
+
username: ${{ github.actor }}
|
|
334
|
+
password: ${{ secrets.GITHUB_TOKEN }}
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
### docker/build-push-action
|
|
338
|
+
|
|
339
|
+
**Latest Version:** v5 (v5.3.0)
|
|
340
|
+
**SHA:** `2cdde995de11925a030ce8070c3d77a52ffcf1c0`
|
|
341
|
+
|
|
342
|
+
**Description:** Build and push Docker images
|
|
343
|
+
|
|
344
|
+
**Common Inputs:**
|
|
345
|
+
- `context`: Build context path
|
|
346
|
+
- `file`: Dockerfile path
|
|
347
|
+
- `push`: Whether to push image (default: `false`)
|
|
348
|
+
- `tags`: Image tags
|
|
349
|
+
- `platforms`: Target platforms (e.g., `linux/amd64,linux/arm64`)
|
|
350
|
+
- `cache-from`: Cache sources
|
|
351
|
+
- `cache-to`: Cache destinations
|
|
352
|
+
- `build-args`: Build arguments
|
|
353
|
+
- `secrets`: Build secrets
|
|
354
|
+
|
|
355
|
+
**Example:**
|
|
356
|
+
```yaml
|
|
357
|
+
- name: Build and push Docker image
|
|
358
|
+
uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 # v5.3.0
|
|
359
|
+
with:
|
|
360
|
+
context: .
|
|
361
|
+
platforms: linux/amd64,linux/arm64
|
|
362
|
+
push: true
|
|
363
|
+
tags: |
|
|
364
|
+
user/app:latest
|
|
365
|
+
user/app:${{ github.sha }}
|
|
366
|
+
cache-from: type=gha
|
|
367
|
+
cache-to: type=gha,mode=max
|
|
368
|
+
build-args: |
|
|
369
|
+
VERSION=${{ github.sha }}
|
|
370
|
+
BUILD_DATE=${{ github.event.head_commit.timestamp }}
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
## Cloud Providers
|
|
374
|
+
|
|
375
|
+
### aws-actions/configure-aws-credentials
|
|
376
|
+
|
|
377
|
+
**Latest Version:** v4 (v4.0.2)
|
|
378
|
+
**SHA:** `e3dd6a429d7300a6a4c196c26e071d42e0343502`
|
|
379
|
+
|
|
380
|
+
**Description:** Configure AWS credentials for GitHub Actions
|
|
381
|
+
|
|
382
|
+
**Common Inputs:**
|
|
383
|
+
- `aws-access-key-id`: AWS access key ID
|
|
384
|
+
- `aws-secret-access-key`: AWS secret access key
|
|
385
|
+
- `aws-region`: AWS region
|
|
386
|
+
- `role-to-assume`: IAM role ARN for OIDC
|
|
387
|
+
- `role-session-name`: Session name
|
|
388
|
+
|
|
389
|
+
**Example (with secrets):**
|
|
390
|
+
```yaml
|
|
391
|
+
- name: Configure AWS credentials
|
|
392
|
+
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
|
|
393
|
+
with:
|
|
394
|
+
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
|
395
|
+
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
|
396
|
+
aws-region: us-east-1
|
|
397
|
+
```
|
|
398
|
+
|
|
399
|
+
**Example (with OIDC - preferred):**
|
|
400
|
+
```yaml
|
|
401
|
+
- name: Configure AWS credentials
|
|
402
|
+
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
|
|
403
|
+
with:
|
|
404
|
+
role-to-assume: arn:aws:iam::123456789012:role/GitHubActionsRole
|
|
405
|
+
role-session-name: GitHubActions-${{ github.run_id }}
|
|
406
|
+
aws-region: us-east-1
|
|
407
|
+
```
|
|
408
|
+
|
|
409
|
+
### azure/login
|
|
410
|
+
|
|
411
|
+
**Latest Version:** v2 (v2.0.0)
|
|
412
|
+
**SHA:** `6c251865b4e6290e7b78be643ea2d005a6c79ee5`
|
|
413
|
+
|
|
414
|
+
**Description:** Login to Azure
|
|
415
|
+
|
|
416
|
+
**Common Inputs:**
|
|
417
|
+
- `creds`: Azure credentials JSON
|
|
418
|
+
- `client-id`: Service principal client ID (for OIDC)
|
|
419
|
+
- `tenant-id`: Azure tenant ID (for OIDC)
|
|
420
|
+
- `subscription-id`: Azure subscription ID (for OIDC)
|
|
421
|
+
|
|
422
|
+
**Example:**
|
|
423
|
+
```yaml
|
|
424
|
+
- name: Azure Login
|
|
425
|
+
uses: azure/login@6c251865b4e6290e7b78be643ea2d005a6c79ee5 # v2.0.0
|
|
426
|
+
with:
|
|
427
|
+
creds: ${{ secrets.AZURE_CREDENTIALS }}
|
|
428
|
+
```
|
|
429
|
+
|
|
430
|
+
## Testing and Code Quality
|
|
431
|
+
|
|
432
|
+
### codecov/codecov-action
|
|
433
|
+
|
|
434
|
+
**Latest Version:** v4 (v4.0.1)
|
|
435
|
+
**SHA:** `e0b68c6749509c5f83f984dd99a76a1c1a231044`
|
|
436
|
+
|
|
437
|
+
**Description:** Upload code coverage to Codecov
|
|
438
|
+
|
|
439
|
+
**Common Inputs:**
|
|
440
|
+
- `token`: Codecov token
|
|
441
|
+
- `files`: Coverage files to upload
|
|
442
|
+
- `fail_ci_if_error`: Fail CI if upload fails
|
|
443
|
+
|
|
444
|
+
**Example:**
|
|
445
|
+
```yaml
|
|
446
|
+
- name: Upload coverage to Codecov
|
|
447
|
+
uses: codecov/codecov-action@e0b68c6749509c5f83f984dd99a76a1c1a231044 # v4.0.1
|
|
448
|
+
with:
|
|
449
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
450
|
+
files: ./coverage/lcov.info
|
|
451
|
+
fail_ci_if_error: true
|
|
452
|
+
```
|
|
453
|
+
|
|
454
|
+
### github/super-linter
|
|
455
|
+
|
|
456
|
+
**Latest Version:** v5 (v5.7.2)
|
|
457
|
+
**SHA:** `45fc0d88288beee4701c62761281edfee85655d7`
|
|
458
|
+
|
|
459
|
+
**Description:** Run multiple linters in one action
|
|
460
|
+
|
|
461
|
+
**Common Inputs:**
|
|
462
|
+
- `validate_all_codebase`: Lint entire codebase or just changes
|
|
463
|
+
- `default_branch`: Default branch name
|
|
464
|
+
- `disable_errors`: Don't fail on errors
|
|
465
|
+
|
|
466
|
+
**Example:**
|
|
467
|
+
```yaml
|
|
468
|
+
- name: Lint code
|
|
469
|
+
uses: github/super-linter@45fc0d88288beee4701c62761281edfee85655d7 # v5.7.2
|
|
470
|
+
env:
|
|
471
|
+
VALIDATE_ALL_CODEBASE: false
|
|
472
|
+
DEFAULT_BRANCH: main
|
|
473
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
474
|
+
```
|
|
475
|
+
|
|
476
|
+
## Notifications
|
|
477
|
+
|
|
478
|
+
### slackapi/slack-github-action
|
|
479
|
+
|
|
480
|
+
**Latest Version:** v1 (v1.25.0)
|
|
481
|
+
**SHA:** `6c661ce58804a1a20f6dc5fbee7f0381b469e001`
|
|
482
|
+
|
|
483
|
+
**Description:** Send Slack notifications
|
|
484
|
+
|
|
485
|
+
**Common Inputs:**
|
|
486
|
+
- `webhook-url`: Slack webhook URL
|
|
487
|
+
- `payload`: JSON payload to send
|
|
488
|
+
|
|
489
|
+
**Example:**
|
|
490
|
+
```yaml
|
|
491
|
+
- name: Notify Slack
|
|
492
|
+
uses: slackapi/slack-github-action@6c661ce58804a1a20f6dc5fbee7f0381b469e001 # v1.25.0
|
|
493
|
+
with:
|
|
494
|
+
webhook-url: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
495
|
+
payload: |
|
|
496
|
+
{
|
|
497
|
+
"text": "Build completed: ${{ job.status }}",
|
|
498
|
+
"blocks": [
|
|
499
|
+
{
|
|
500
|
+
"type": "section",
|
|
501
|
+
"text": {
|
|
502
|
+
"type": "mrkdwn",
|
|
503
|
+
"text": "*Status:* ${{ job.status }}\n*Branch:* ${{ github.ref }}"
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
]
|
|
507
|
+
}
|
|
508
|
+
```
|
|
509
|
+
|
|
510
|
+
## Release and Publishing
|
|
511
|
+
|
|
512
|
+
### actions/create-release
|
|
513
|
+
|
|
514
|
+
**Note:** Deprecated. Use `gh release create` or `softprops/action-gh-release` instead.
|
|
515
|
+
|
|
516
|
+
### softprops/action-gh-release
|
|
517
|
+
|
|
518
|
+
**Latest Version:** v2 (v2.0.2)
|
|
519
|
+
**SHA:** `9d7c94cfd0a1f3ed45544c887983e9fa900f0564`
|
|
520
|
+
|
|
521
|
+
**Description:** Create GitHub releases
|
|
522
|
+
|
|
523
|
+
**Common Inputs:**
|
|
524
|
+
- `tag_name`: Release tag (default: from tag trigger)
|
|
525
|
+
- `name`: Release name
|
|
526
|
+
- `body`: Release description
|
|
527
|
+
- `draft`: Create as draft
|
|
528
|
+
- `prerelease`: Mark as prerelease
|
|
529
|
+
- `files`: Files to upload
|
|
530
|
+
|
|
531
|
+
**Example:**
|
|
532
|
+
```yaml
|
|
533
|
+
- name: Create Release
|
|
534
|
+
uses: softprops/action-gh-release@9d7c94cfd0a1f3ed45544c887983e9fa900f0564 # v2.0.2
|
|
535
|
+
with:
|
|
536
|
+
tag_name: ${{ github.ref }}
|
|
537
|
+
name: Release ${{ github.ref_name }}
|
|
538
|
+
body_path: CHANGELOG.md
|
|
539
|
+
draft: false
|
|
540
|
+
prerelease: false
|
|
541
|
+
files: |
|
|
542
|
+
dist/*.zip
|
|
543
|
+
dist/*.tar.gz
|
|
544
|
+
env:
|
|
545
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
546
|
+
```
|
|
547
|
+
|
|
548
|
+
### actions/github-script
|
|
549
|
+
|
|
550
|
+
**Latest Version:** v7 (v7.0.1)
|
|
551
|
+
**SHA:** `60a0d83039c74a4aee543508d2ffcb1c3799cdea`
|
|
552
|
+
|
|
553
|
+
**Description:** Run JavaScript with GitHub API access
|
|
554
|
+
|
|
555
|
+
**Common Inputs:**
|
|
556
|
+
- `script`: JavaScript code to execute
|
|
557
|
+
- `github-token`: GitHub token (default: `${{ github.token }}`)
|
|
558
|
+
|
|
559
|
+
**Example:**
|
|
560
|
+
```yaml
|
|
561
|
+
- name: Create comment
|
|
562
|
+
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
|
|
563
|
+
with:
|
|
564
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
565
|
+
script: |
|
|
566
|
+
github.rest.issues.createComment({
|
|
567
|
+
issue_number: context.issue.number,
|
|
568
|
+
owner: context.repo.owner,
|
|
569
|
+
repo: context.repo.repo,
|
|
570
|
+
body: '👋 Thanks for reporting!'
|
|
571
|
+
})
|
|
572
|
+
```
|
|
573
|
+
|
|
574
|
+
## Security
|
|
575
|
+
|
|
576
|
+
### actions/dependency-review-action
|
|
577
|
+
|
|
578
|
+
**Latest Version:** v4 (v4.8.3)
|
|
579
|
+
**SHA:** `05fe4576374b728f0c523d6a13d64c25081e0803`
|
|
580
|
+
**Description:** Scans pull requests for vulnerable dependency versions
|
|
581
|
+
|
|
582
|
+
**Required Permissions:**
|
|
583
|
+
```yaml
|
|
584
|
+
permissions:
|
|
585
|
+
contents: read
|
|
586
|
+
```
|
|
587
|
+
|
|
588
|
+
**Common Inputs:**
|
|
589
|
+
- `fail-on-severity`: Severity level to fail on (`low`, `moderate`, `high`, `critical`)
|
|
590
|
+
- `allow-licenses`: Comma-separated list of allowed licenses
|
|
591
|
+
- `deny-licenses`: Comma-separated list of denied licenses
|
|
592
|
+
|
|
593
|
+
**Example:**
|
|
594
|
+
```yaml
|
|
595
|
+
- name: Dependency Review
|
|
596
|
+
uses: actions/dependency-review-action@05fe4576374b728f0c523d6a13d64c25081e0803 # v4.8.3
|
|
597
|
+
with:
|
|
598
|
+
fail-on-severity: critical
|
|
599
|
+
allow-licenses: MIT, Apache-2.0, BSD-3-Clause
|
|
600
|
+
```
|
|
601
|
+
|
|
602
|
+
### actions/attest-sbom
|
|
603
|
+
|
|
604
|
+
**Latest Version:** v2 (v2.4.0)
|
|
605
|
+
**SHA:** `bd218ad0dbcb3e146bd073d1d9c6d78e08aa8a0b`
|
|
606
|
+
**Description:** Generate SBOM attestations for artifacts
|
|
607
|
+
|
|
608
|
+
**Required Permissions:**
|
|
609
|
+
```yaml
|
|
610
|
+
permissions:
|
|
611
|
+
id-token: write
|
|
612
|
+
contents: read
|
|
613
|
+
attestations: write
|
|
614
|
+
packages: write # For container registry
|
|
615
|
+
```
|
|
616
|
+
|
|
617
|
+
**Example:**
|
|
618
|
+
```yaml
|
|
619
|
+
- name: Generate SBOM attestation
|
|
620
|
+
uses: actions/attest-sbom@bd218ad0dbcb3e146bd073d1d9c6d78e08aa8a0b # v2.4.0
|
|
621
|
+
with:
|
|
622
|
+
subject-name: ${{ env.REGISTRY }}/myapp
|
|
623
|
+
subject-digest: sha256:${{ steps.build.outputs.digest }}
|
|
624
|
+
sbom-path: sbom.json
|
|
625
|
+
push-to-registry: true
|
|
626
|
+
```
|
|
627
|
+
|
|
628
|
+
### actions/attest-build-provenance
|
|
629
|
+
|
|
630
|
+
**Latest Version:** v2 (v2.4.0)
|
|
631
|
+
**SHA:** `e8998f949152b193b063cb0ec769d69d929409be`
|
|
632
|
+
**Description:** Generate build provenance attestations for build artifacts
|
|
633
|
+
|
|
634
|
+
**Required Permissions:**
|
|
635
|
+
```yaml
|
|
636
|
+
permissions:
|
|
637
|
+
id-token: write
|
|
638
|
+
contents: read
|
|
639
|
+
attestations: write
|
|
640
|
+
packages: write # For container registry
|
|
641
|
+
```
|
|
642
|
+
|
|
643
|
+
**Example:**
|
|
644
|
+
```yaml
|
|
645
|
+
- name: Generate provenance attestation
|
|
646
|
+
uses: actions/attest-build-provenance@e8998f949152b193b063cb0ec769d69d929409be # v2.4.0
|
|
647
|
+
with:
|
|
648
|
+
subject-name: ${{ env.REGISTRY }}/myapp
|
|
649
|
+
subject-digest: sha256:${{ steps.build.outputs.digest }}
|
|
650
|
+
push-to-registry: true
|
|
651
|
+
```
|
|
652
|
+
|
|
653
|
+
### github/codeql-action
|
|
654
|
+
|
|
655
|
+
**Latest Version:** v3 (v3.32.5)
|
|
656
|
+
**SHA:** `ae9ef3a1d2e3413523c3741725c30064970cc0d4`
|
|
657
|
+
**Description:** GitHub CodeQL scanning actions (`init`, `analyze`, `upload-sarif`)
|
|
658
|
+
|
|
659
|
+
**Required Permissions:**
|
|
660
|
+
```yaml
|
|
661
|
+
permissions:
|
|
662
|
+
contents: read
|
|
663
|
+
security-events: write
|
|
664
|
+
```
|
|
665
|
+
|
|
666
|
+
**Example:**
|
|
667
|
+
```yaml
|
|
668
|
+
- name: Initialize CodeQL
|
|
669
|
+
uses: github/codeql-action/init@ae9ef3a1d2e3413523c3741725c30064970cc0d4 # v3.32.5
|
|
670
|
+
with:
|
|
671
|
+
languages: javascript
|
|
672
|
+
|
|
673
|
+
- name: Upload SARIF
|
|
674
|
+
if: always()
|
|
675
|
+
uses: github/codeql-action/upload-sarif@ae9ef3a1d2e3413523c3741725c30064970cc0d4 # v3.32.5
|
|
676
|
+
with:
|
|
677
|
+
sarif_file: trivy-results.sarif
|
|
678
|
+
```
|
|
679
|
+
|
|
680
|
+
## Best Practices Summary (Updated November 2025)
|
|
681
|
+
|
|
682
|
+
1. **Always pin to full SHA**: Use 40-character SHA with version comment
|
|
683
|
+
2. **Node 24 migration**: Migrate to Node 24 before March 2026 (Node 20 EOL April 2026)
|
|
684
|
+
3. **Cache v4.3.0**: Use latest cache version (v4.2.0+ required, legacy service retired Feb 2025)
|
|
685
|
+
4. **Use official actions**: Prefer verified `actions/*`, `docker/*`, etc.
|
|
686
|
+
5. **Security scanning**: Implement dependency review and SBOM attestations
|
|
687
|
+
6. **Minimal permissions**: Use explicit `permissions:` blocks
|
|
688
|
+
7. **Keep up to date**: Monitor releases and security advisories
|
|
689
|
+
8. **Document versions**: Add comments explaining version choices
|
|
690
|
+
|
|
691
|
+
## Finding Action Documentation
|
|
692
|
+
|
|
693
|
+
**Search Pattern:**
|
|
694
|
+
```
|
|
695
|
+
"[owner/repo] [version] github action documentation"
|
|
696
|
+
```
|
|
697
|
+
|
|
698
|
+
**Example:**
|
|
699
|
+
```
|
|
700
|
+
"docker/build-push-action v5 github documentation"
|
|
701
|
+
"actions/checkout v5 sparse-checkout"
|
|
702
|
+
```
|
|
703
|
+
|
|
704
|
+
**Official Sources:**
|
|
705
|
+
- GitHub Marketplace: https://github.com/marketplace
|
|
706
|
+
- Action repository: https://github.com/[owner]/[repo]
|
|
707
|
+
- Release notes: https://github.com/[owner]/[repo]/releases
|
|
708
|
+
- Context7: Use for structured documentation lookup
|
|
709
|
+
|
|
710
|
+
**Version Verification:**
|
|
711
|
+
- Check releases page for latest version
|
|
712
|
+
- Find SHA from tags: `git ls-remote https://github.com/[owner]/[repo] [tag]`
|
|
713
|
+
- Verify minimum runner requirements
|
|
714
|
+
|
|
715
|
+
Always verify action inputs and outputs from official documentation before use.
|