Compare commits
4
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b32e56c10a | ||
|
|
1fded69ee8 | ||
|
|
4ec685b4f6 | ||
|
|
aba119ddd2 |
No files matched your search
@@ -28,7 +28,7 @@ jobs:
|
||||
timeout-minutes: 30
|
||||
# The ci image (images/ci, built by image.yml): tag for the release, digest enforced.
|
||||
container:
|
||||
image: git.rkdr.net/mortis/ci:0.2.42@sha256:6dc6906aaf407ccff74adcaade5dc7a810cb3ffcc1a6caa9df26b94dfe1632f7
|
||||
image: git.rkdr.net/mortis/ci:0.2.43@sha256:373c3ba69e3cdccdf6acf96d9c1cbfa173d2db0fbda441f4256eb46bd3ce6b99
|
||||
env:
|
||||
PIP_DISABLE_PIP_VERSION_CHECK: "1"
|
||||
steps:
|
||||
|
||||
@@ -44,7 +44,7 @@ jobs:
|
||||
# The ci image (images/ci, built by image.yml), at the pin of lint.yml: tag for the
|
||||
# release, digest enforced. Only its /opt/venv Python (with PyYAML) is used here.
|
||||
container:
|
||||
image: git.rkdr.net/mortis/ci:0.2.42@sha256:6dc6906aaf407ccff74adcaade5dc7a810cb3ffcc1a6caa9df26b94dfe1632f7
|
||||
image: git.rkdr.net/mortis/ci:0.2.43@sha256:373c3ba69e3cdccdf6acf96d9c1cbfa173d2db0fbda441f4256eb46bd3ce6b99
|
||||
steps:
|
||||
# The container has no Node, so JavaScript actions such as actions/checkout
|
||||
# cannot run; clone with git and the job token.
|
||||
|
||||
@@ -63,8 +63,7 @@ jobs:
|
||||
github.ref == 'refs/heads/main'
|
||||
runs-on: kamino-docker
|
||||
timeout-minutes: 45
|
||||
# max-parallel: 1 keeps the builds to one at a time. The runner takes two jobs, so a build
|
||||
# may share it with one other job (Lint, Build or Molecule). An empty subpath means the
|
||||
# One job at a time on the single-capacity runner. An empty subpath means the
|
||||
# repository root is the build context.
|
||||
#
|
||||
# base: MAJOR.MINOR of the image's semver tags, independent of the Collection's releases;
|
||||
|
||||
@@ -31,7 +31,7 @@ jobs:
|
||||
# The tag says which release, the digest is what is enforced (bump both together
|
||||
# when image.yml publishes a new version).
|
||||
container:
|
||||
image: git.rkdr.net/mortis/ci:0.2.42@sha256:6dc6906aaf407ccff74adcaade5dc7a810cb3ffcc1a6caa9df26b94dfe1632f7
|
||||
image: git.rkdr.net/mortis/ci:0.2.43@sha256:373c3ba69e3cdccdf6acf96d9c1cbfa173d2db0fbda441f4256eb46bd3ce6b99
|
||||
env:
|
||||
PIP_DISABLE_PIP_VERSION_CHECK: "1"
|
||||
PRE_COMMIT_HOME: /opt/pre-commit
|
||||
|
||||
@@ -47,14 +47,13 @@ jobs:
|
||||
(github.event_name != 'pull_request' ||
|
||||
github.event.pull_request.head.repo.full_name == github.repository)
|
||||
runs-on: [kamino-molecule]
|
||||
# Two full runs sharing the runner (a nightly run and a dispatch) take more than 30 minutes.
|
||||
# Also the age past which the sweep step removes a run's containers; a script test holds the
|
||||
# two equal.
|
||||
timeout-minutes: 45
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
# The tools and collections molecule runs with: the image Lint and Build use.
|
||||
CI_IMAGE: >-
|
||||
git.rkdr.net/mortis/ci:0.2.42@sha256:6dc6906aaf407ccff74adcaade5dc7a810cb3ffcc1a6caa9df26b94dfe1632f7
|
||||
git.rkdr.net/mortis/ci:0.2.43@sha256:373c3ba69e3cdccdf6acf96d9c1cbfa173d2db0fbda441f4256eb46bd3ce6b99
|
||||
# Used by the scenarios as `image: ${MOLECULE_IMAGE}`; set it the same way to run
|
||||
# one locally.
|
||||
MOLECULE_IMAGE: >-
|
||||
@@ -98,7 +97,7 @@ jobs:
|
||||
ids="$(docker ps -aq --filter 'label=net.rkdr.mortis.molecule-run')"
|
||||
# The job's timeout-minutes (a script test holds them equal): a shorter bound would remove a
|
||||
# live run's containers.
|
||||
cutoff="$(date -d '45 minutes ago' +%s)"
|
||||
cutoff="$(date -d '30 minutes ago' +%s)"
|
||||
old=""
|
||||
for id in $ids; do
|
||||
# a container removed since the listing, by its run or another run's sweep, is skipped
|
||||
|
||||
@@ -114,6 +114,16 @@ repos:
|
||||
require_serial: true
|
||||
stages: ['pre-push']
|
||||
|
||||
# SECURITY.md's accepted risks rest on the Collection shipping roles only. It sits before
|
||||
# ansible-lint, whose fail_fast would otherwise hide this message.
|
||||
- id: refuse-plugins
|
||||
name: Refuse a plugins/ directory
|
||||
description: refuse any file under plugins/
|
||||
entry: the Collection holds roles only; a plugin needs an ADR in docs/adr/ first, and that ADR's pull request removes this hook
|
||||
language: fail
|
||||
files: ^plugins/
|
||||
stages: ['pre-commit']
|
||||
|
||||
- id: ansible-lint
|
||||
name: ansible-lint
|
||||
description: ansible-lint production profile, offline
|
||||
@@ -136,6 +146,17 @@ repos:
|
||||
files: (?i)(^|/)(\.claude/)?claude(\.local)?\.md$
|
||||
stages: ['pre-commit']
|
||||
|
||||
# Agent tools write these trailers by default. pygrep prints only the hook's name and the
|
||||
# matching line, so the name carries the rule. Claude is also a person's name, so it matches
|
||||
# only as a trailer's whole name ("Claude <"); a human Co-Authored-By: stays allowed.
|
||||
- id: refuse-agent-trailers
|
||||
name: "Agent work carries Assisted-by: <tool>[:<model>], never an agent Co-Authored-By: or a session link (docs/contributing/ai-assistance.md)"
|
||||
description: refuse Claude-Session and Co-Authored-By lines naming a known agent identity
|
||||
entry: '^(claude-session:|co-authored-by:\s*claude\s*<|co-authored-by:.*(noreply@anthropic\.com|\b(copilot|cursor|gemini|codex)\b))'
|
||||
language: pygrep
|
||||
args: [--ignore-case]
|
||||
stages: [commit-msg]
|
||||
|
||||
- repo: meta
|
||||
hooks:
|
||||
- id: check-hooks-apply
|
||||
|
||||
@@ -46,8 +46,8 @@ held: by a control (a named hook or check), by review, or aspirational (checked
|
||||
`Co-Authored-By:` for an agent, a session link or any other AI trailer**
|
||||
([ai-assistance.md](docs/contributing/ai-assistance.md)).
|
||||
*Reason:* AI assistance is disclosed (principle 7), and an agent is not an author (principle 1).
|
||||
*Held by:* review; the exclusion becomes a control when the commit-msg hook that refuses these
|
||||
trailers lands (#272).
|
||||
*Held by:* control in part: the `refuse-agent-trailers` commit-msg hook refuses `Claude-Session:`
|
||||
and a `Co-Authored-By:` naming a known agent; review for the rest and for `Assisted-by:`.
|
||||
- **On conflict with a shared rule delivered by apm, this repository's `AGENTS.md` wins.**
|
||||
*Reason:* this repository's rules are reviewed here, for this repository.
|
||||
*Held by:* aspirational.
|
||||
|
||||
@@ -33,8 +33,8 @@ contributor docs are held by review until an offline link check exists. Terms su
|
||||
History is not rewritten.
|
||||
*Reason:* a co-author trailer makes the tool an author, and a session link is private and points
|
||||
outside this repository.
|
||||
*Held by:* review until the commit-msg hook that refuses these trailers lands (issue #272); then
|
||||
control.
|
||||
*Held by:* control in part: the `refuse-agent-trailers` commit-msg hook refuses `Claude-Session:`
|
||||
and a `Co-Authored-By:` naming a known agent; review for the rest.
|
||||
|
||||
## What agents may do
|
||||
|
||||
|
||||
Reference in new issue
Block a user