Repository navigation
Expand file tree
/
Copy pathintent.yaml
More file actions
172 lines (159 loc) · 5.85 KB
/
Copy pathintent.yaml
File metadata and controls
172 lines (159 loc) · 5.85 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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
apiVersion: sourceplane.io/v1
kind: Intent
metadata:
name: hono-api
description: A Hono API on one Cloudflare Worker — the welcome route and a JSON health check, deployed to stage and prod
namespace: sourceplane
execution:
state:
backendUrl: https://api-edge-prod.oruncloud.workers.dev
# Declared, enforced tenancy: the workspace claim is sent on every remote op
# (including the credential-free CI OIDC exchange) so the platform can
# enforce claim ⊆ authorized. Declaring it implies strict mode — a
# non-interactive run that resolves no workspace fails fast.
#
# `ws_CHANGE_ME` is the one value `ci.yml` treats as "not linked yet" and
# plans nothing for. A bootstrap writes the product's workspace here; by
# hand, set it to yours (`orun cloud link`) and the Orun pipeline runs.
workspace: ws_CHANGE_ME
requireOrg: true
# Push the resolved catalog after a successful plan on the default branch,
# keeping the workspace-global catalog head fresh without an explicit
# `--push-catalog`.
autopushCatalog: true
# Lanes (orun ≥ v2.76.0): CI runs one GitHub job per LANE, not per orun job.
lanes:
mode: auto
maxLanes: 6
concurrency: 6
compositions:
sources:
# The composition stack lives in sourceplane/stack-tectonic and is consumed
# as a published OCI artifact rather than a repo-local directory. Pin an
# explicit version: a bare repository reference resolves to `:latest`,
# which would let a catalog release change this repo's execution contracts
# without a commit here. Bumping the tag is the deliberate upgrade step.
#
# 0.19.0, NOT 0.20.0 (cirrus-baseline's pin). 0.20.0 makes the workspace
# install lane-scoped: it runs once in the source checkout and every job's
# staged tree LINKS its top-level node_modules there — out of the tree.
# Next 16's Turbopack refuses a dependency that resolves outside its root
# ("Symlink … points out of the filesystem root"), so the Next.js products
# on these conventions pin 0.19.0, and this one keeps the same pin for one
# convention. This Worker builds with wrangler's esbuild, which follows the
# link, but under 0.19.0 each job installs inside its own tree, and the API
# has one job per lane, so the shared install would save nothing anyway.
# 0.19.0 also retries a first deploy that loses Cloudflare's 10007 race and
# retries the smoke while a new workers.dev route propagates. A bump is a
# deliberate pull request that re-runs the lane's steps in a job tree
# staged with the new layout.
- name: stack-tectonic
kind: oci
ref: oci://ghcr.io/sourceplane/stack-tectonic:0.19.1
resolution:
precedence:
- stack-tectonic
bindings:
terraform: stack-tectonic
cloudflare-domain: stack-tectonic
db-migrate: stack-tectonic
# The live preview (saas-parallel-baselining PB4): the component orun.work's
# Preview tab shows while a coding session works on the API. Its own
# `spec.preview` (apps/api/component.yaml) says how it runs; `orun preview`
# runs it.
preview:
component: api
discovery:
roots:
- apps/
- infra/
- packages/
- tests/
# Where the work lives (initiative-lifecycle): an epic is a directory with an
# epic.yaml under `epics`, a task a contract under `tasks`; the `orun plan` on
# main reconciles the tree into the workspace's work plane after a merge.
#
# THIS BLOCK IS THE BASELINE'S OWN. An API built from this baseline has no
# `specs/` and no `tasks/` (its bootstrap work lives on the platform), so
# 01-product removes the block, and this comment with it, from the
# product's copy (tooling/bootstrap/work-tree.mjs).
work:
epics: specs/epics
tasks: tasks
sync: on-merge
automation:
triggerBindings:
github-pull-request:
description: Pull request validation
on:
provider: github
event: pull_request
actions:
- opened
- synchronize
- reopened
- ready_for_review
baseBranches:
- main
plan:
scope: changed
base: pull_request.base.sha
head: pull_request.head.sha
github-push-main:
description: Main branch stack convergence after merge
on:
provider: github
event: push
branches:
- main
local-development:
description: Local testing with full Terraform execution
on:
provider: local
environments:
dev:
description: Verify-only. Pull requests plan and verify here; nothing is deployed.
activation:
triggerRefs:
- github-pull-request
- github-push-main
- local-development
dependencyMode: advisory
policies:
requireApproval: "false"
env:
BASE_DOMAIN: hono-api.example.com
stage:
description: Deployed on every merge to main, before prod.
url: https://hono-api-api-stage.your-workers-subdomain.workers.dev
activation:
triggerRefs:
- github-pull-request
- github-push-main
policies:
requireApproval: "false"
env:
BASE_DOMAIN: hono-api.example.com
prod:
description: Where visitors are. Deploys after stage converges on the same commit.
url: https://hono-api-api-prod.your-workers-subdomain.workers.dev
activation:
triggerRefs:
- github-pull-request
- github-push-main
promotion:
dependsOn:
- environment: stage
policies:
requireApproval: "false"
env:
BASE_DOMAIN: hono-api.example.com
# Repo-level catalog entity: front page + role-tagged docs (rendered in the
# workspace Docs library, pinned to the commit by `orun plan`).
repo:
displayName: hono-api
docs:
overview: README.md
pages:
- { path: ai/context/operations.md, role: runbook, title: Operating contract }
- { path: ai/context/deployment.md, role: reference, title: Live deployment manifest }