Skip to content
Merged
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
35 changes: 35 additions & 0 deletions .github/workflows/camara-validation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# CAMARA Validation Framework — Caller Workflow
#
# Copy this file to .github/workflows/camara-validation.yml in your
# API repository. No modification needed — all configuration is
# centralized in the tooling repository.
#
# This replaces the v0 pr_validation_caller.yml for repositories that
# have opted into the v1 validation framework.

name: CAMARA Validation

on:
pull_request:
branches:
- main
- release-snapshot/**
- maintenance/**
workflow_dispatch:

concurrency:
group: ${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true

permissions:
checks: write
pull-requests: write
issues: write
contents: read
statuses: write
id-token: write

jobs:
validation:
uses: camaraproject/tooling/.github/workflows/validation.yml@v1-rc
secrets: inherit
93 changes: 93 additions & 0 deletions .github/workflows/release-automation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# Release Automation Caller Workflow
#
# This workflow template should be copied to .github/workflows/ in API repositories
# that want to use the CAMARA release automation.
#
# Copy this file as: .github/workflows/release-automation.yml
#
# Triggers:
# - Slash commands: /create-snapshot, /discard-snapshot, /delete-draft, /publish-release
# - Issue events: close (with auto-reopen), reopen
# - PR merge: on release-snapshot branches (creates draft release)
# - Push to main: on release-plan.yaml, code/common/**, or this caller
# workflow itself. All three paths end up running sync-issue so the
# Release Issue body reflects the current repo state — most notably,
# pushing to code/common/** (typically after a sync PR merge) refreshes
# the common-cache status in the Release Issue and clears any stale warning.
# - Manual: workflow_dispatch triggers sync-issue (reads from release-plan.yaml)

name: CAMARA Release Automation

on:
# Slash commands via issue comments
issue_comment:
types: [created]

# Issue close/reopen events
issues:
types: [closed, reopened]

# PR merge to snapshot branches
pull_request:
types: [closed]
branches:
- 'release-snapshot/**'

# Push to main with release-plan.yaml, common file, or caller workflow changes.
# Listing the caller itself as a path ensures the workflow runs once right
# after it is merged (future caller updates pick up their own trigger).
push:
branches: [main]
paths:
- 'release-plan.yaml'
- 'code/common/**'
- '.github/workflows/release-automation.yml'

# Manual trigger for sync-issue only
# Use this for: initial setup, recovery after manual repo changes, or forced sync
# All other commands must be issued via slash commands in the Release Issue
# Future: will accept branch input (main by default, maintenance branches as option)
workflow_dispatch:

# Serialize release automation runs per repository.
# Prevents race conditions from concurrent slash commands, issue events, PR merges,
# and workflow_dispatch triggers. With cancel-in-progress: false, queued runs wait
# for the current run to complete before starting.
# Note: GitHub allows at most 1 running + 1 pending per concurrency group.
# A third arrival replaces the pending run (acceptable — codeowners act carefully).
concurrency:
group: release-automation-${{ github.repository }}
cancel-in-progress: false

permissions:
contents: write
issues: write
pull-requests: write
id-token: write

jobs:
release-automation:
# Skip if:
# - issue_comment from the RA bot itself (its own replies, to prevent self-triggering)
# - issue_comment but not a release command or not on a release issue
# - issues event but not a release issue
# - pull_request but not merged or not to a snapshot branch
if: |
(github.event_name == 'push') ||
github.event_name == 'workflow_dispatch' ||
(github.event_name == 'issue_comment' &&
github.event.comment.user.login != 'camara-release-automation[bot]' &&
contains(github.event.issue.labels.*.name, 'release-issue') &&
(startsWith(github.event.comment.body, '/create-snapshot') ||
startsWith(github.event.comment.body, '/discard-snapshot') ||
startsWith(github.event.comment.body, '/delete-draft') ||
startsWith(github.event.comment.body, '/publish-release') ||
startsWith(github.event.comment.body, '/sync-issue'))) ||
(github.event_name == 'issues' &&
contains(github.event.issue.labels.*.name, 'release-issue')) ||
(github.event_name == 'pull_request' &&
github.event.pull_request.merged == true &&
startsWith(github.event.pull_request.base.ref, 'release-snapshot/'))

uses: camaraproject/tooling/.github/workflows/release-automation-reusable.yml@v1-rc
secrets: inherit
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
> Starting with release automation, new release changelogs are maintained
> in the [CHANGELOG/](CHANGELOG/) directory with per-cycle files.

# Device Identifier Changelog
> **Please be aware that the project will have frequent updates to the main branch. There are no compatibility guarantees associated with code in any branch, including main, until it has been released. For example, changes may be reverted before a release is published.
For the best results, use the latest published release.**
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Changelog

Release changelogs are organized by release cycle.

For historical release notes predating the automated release process,
see [CHANGELOG.md](../CHANGELOG.md) in the repository root.
Loading