Record verified releases and prepare recovery exercises
This commit is contained in:
@@ -2,14 +2,17 @@
|
||||
|
||||
## Reviewed Jenkins execution, 15 November 2026
|
||||
|
||||
PRs 24 and 25 are merged. The actual [test/secret gate demonstrations](evidence/gates-20261115.md)
|
||||
PRs 24–26 are merged. The actual [test/secret gate demonstrations](evidence/gates-20261115.md)
|
||||
blocked as intended. [Release attempt 3](evidence/release-attempt-3-20261115.md)
|
||||
published v1 and stopped at the Ansible PTY request. After that correction
|
||||
merged, [release attempt 4](evidence/release-attempt-4-20261115.md) passed initial
|
||||
staging checks but its unchanged rerun stopped at Docker's health timeout.
|
||||
Eight isolated diagnostic probes passed with ten seconds instead of three.
|
||||
That correction and the separate v2 source/test change await review. No passed
|
||||
idempotence gate, production approval, promotion or recovery is claimed.
|
||||
After review, [builds 5 and 6](evidence/releases-20261115.md) completed v1/v2
|
||||
promotions, zero-change reruns and actual human approvals. Production monitoring
|
||||
is live; one HTTP 502 sample during v2 replacement is preserved. The exact
|
||||
successful records and staging-only fault/revert history await review before
|
||||
recovery. Both recovery exercises remain unexecuted.
|
||||
|
||||
## Preparation evidence — historical baseline
|
||||
|
||||
|
||||
+22
-19
@@ -1,23 +1,26 @@
|
||||
# Fix constrained health checks and add pricing v2
|
||||
# Record verified releases and prepare the recovery exercises
|
||||
|
||||
Pricing build 4 passed tests/scans and deployed v1 staging with correct HTTPS,
|
||||
source identity and total 30. Its unchanged rerun stopped because Docker's
|
||||
three-second health deadline was too short for Python startup under the
|
||||
0.25 CPU cap. Keep the two-second HTTP timeout and all security/resource limits;
|
||||
extend only Docker's overall health timeout to ten seconds.
|
||||
Jenkins builds 5 and 6 completed reviewed v1/v2 delivery: tests/scans passed,
|
||||
unchanged staging reruns had changed=0, Vincent approved each production input,
|
||||
and each exact digest was promoted without rebuilding. Copy their four actual
|
||||
release selectors into Git so recovery can use reviewed known-good records.
|
||||
Preserve failed attempts, approvals, timings and scan hashes as evidence.
|
||||
|
||||
An isolated trial of the same reviewed image passed eight consecutive checks
|
||||
in 2.817–5.660 seconds under identical limits. The temporary container had no
|
||||
network, published port or proxy alias and was removed afterward. Preserve the
|
||||
actual failed gate and diagnostic evidence; no production approval is claimed.
|
||||
The reviewed production probe/panel was applied after healthy v1 and verified
|
||||
in Prometheus and the Grafana UI. Record the single HTTP 502 sample during v2
|
||||
replacement; zero downtime and unobserved alert notifications are not claimed.
|
||||
Include the guarded operator helper and current manual/inventory updates.
|
||||
|
||||
Also prepare the required v2 source/tests: version v2, unit price 12, total 36.
|
||||
Keep two commits: first the health fix with v1 source, then the v2 app/test
|
||||
change. Review both and merge with a merge commit, preserving both SHAs.
|
||||
Jenkins will release the first commit as v1, then the second as v2, each with
|
||||
staging/idempotence checks and separate human production approval. Recovery
|
||||
records will be saved from actual successful builds and reviewed afterward.
|
||||
The recovery fixture deliberately binds Gunicorn to 8001 only in staging,
|
||||
while health still probes 8000. Keep three commits in this PR: records/evidence
|
||||
and the patch; the staging-only template fault; its immediate revert. Review
|
||||
all three, including the intermediate bad configuration. Merge with a merge
|
||||
commit, preserving that SHA while the final main template remains correct.
|
||||
The explicit Jenkins staging-failure mode selects that historical configuration;
|
||||
merging alone does not deploy it. Both recovery executions remain pending.
|
||||
|
||||
Validation: eight constrained diagnostic probes passed; three local functional
|
||||
tests and twelve control tests passed. Local functional tests used Flask 3.1.3
|
||||
and Werkzeug 3.1.8; assessed Jenkins runs retain the exact 3.1.9 dependency lock.
|
||||
Validation: successful Jenkins builds 5/6, real approval records, strict selector
|
||||
verification for all four records, post-release HTTPS identity/price/400 checks,
|
||||
all six scrape targets up, successful reload and the live production panel.
|
||||
The failure patch passes git apply --check and local staging/production isolation
|
||||
checks. No credential or access scope changed.
|
||||
|
||||
+20
-19
@@ -11,21 +11,20 @@ The inventory selects The-Ocean's dedicated deploy account. The example
|
||||
release record remains explicitly an example; real registry digests are
|
||||
generated by Jenkins from reviewed source.
|
||||
|
||||
Current execution status, 15 November: PR 24 is merged and the delivery job
|
||||
is enabled. Real Jenkins test/secret demonstrations blocked as intended. The
|
||||
first v1 image was scanned and published, but staging stopped at a PTY request.
|
||||
PR 25's noninteractive correction is now merged. Build 4 passed initial staging
|
||||
health/identity/price checks, then the unchanged rerun blocked on the three-second
|
||||
Docker health deadline. Eight diagnostic probes passed at ten seconds under the
|
||||
same limits. This health correction and a separate v2 source/test change await
|
||||
review. See [build 4 and the trial](evidence/release-attempt-4-20261115.md).
|
||||
Current execution status, 15 November Eastern / 16 November UTC: PRs 24–26
|
||||
are merged, preserving the separate v1/v2 commits. Real Jenkins test/secret
|
||||
demonstrations blocked as intended. Builds 5 and 6 then completed both releases,
|
||||
with zero-change staging reruns, passing gates and actual human production
|
||||
approvals. Both environments are healthy v2; production monitoring is live.
|
||||
See [release evidence](evidence/releases-20261115.md). The four successful
|
||||
records and staging-only fault history need review before the two remaining
|
||||
[recovery exercises](exercises/README.md). Earlier failures/trials remain
|
||||
historical evidence, not the current release result.
|
||||
|
||||
Run the tests from `app/` after installing its requirements into the selected
|
||||
Linux test environment. The expected v1 result for three units is USD 30.
|
||||
The prepared v2 source/test change returns USD 36 and must be committed
|
||||
separately after the v1 health correction. Review both in one PR and use a
|
||||
merge commit, preserving both SHAs: select the first for v1, then the second
|
||||
for v2. The source commit must be baked into each built image.
|
||||
The reviewed v2 source/test change returns USD 36. PR 26 preserved the separate
|
||||
v1 and v2 SHAs, selected explicitly by builds 5 and 6 and baked into each image.
|
||||
|
||||
Deployment work uses a dedicated trusted Jenkins agent, immutable images
|
||||
in the existing Gitea registry, and separate Ansible-managed staging and
|
||||
@@ -105,21 +104,23 @@ See `RUNBOOKS.md`.
|
||||
|
||||
Ansible syntax, agent Compose configuration, and the installed Jenkins
|
||||
controller's declarative parser checks passed. These are preparation checks;
|
||||
**successful v1/v2 deployment, promotion and recovery are not yet demonstrated**.
|
||||
The subsequent actual release evidence is linked above; **the two recovery
|
||||
exercises remain unexecuted**.
|
||||
|
||||
## Remaining checkpoints
|
||||
|
||||
Vincent merged PR #24, including runner migration and HTTPS, after Billy's
|
||||
latest review; PR 25's SSH correction is also merged. Review/merge the health
|
||||
correction and separate v2 commit before retrying v1. Preserve their history
|
||||
with a merge commit. Create the assignment issue if still absent. Keep main protection.
|
||||
latest review; PR 25's SSH correction and PR 26's two source commits are also
|
||||
merged. Review/merge the actual successful records and the preserved staging-only
|
||||
fault/revert commits before recovery. Create the assignment issue if still absent.
|
||||
Keep main protection and preserve commit history with a merge commit.
|
||||
Billy added the A
|
||||
records; Google and Cloudflare now resolve both names to `147.182.178.136`.
|
||||
On 15 November Caddy's prepared routes were validated and gracefully reloaded;
|
||||
both names have trusted HTTPS and HTTP redirects. Staging v1 now exists and
|
||||
passed its first HTTPS checks; production still returns 502. The original TLS
|
||||
both names have trusted HTTPS and HTTP redirects. Both environments now passed
|
||||
v1/v2 release checks and are healthy v2. The original TLS
|
||||
readiness snapshot is `evidence/https-20261115.md`.
|
||||
The release job is enabled; follow `RUNBOOKS.md` after the corrected source reaches main.
|
||||
The release job is enabled; follow `RUNBOOKS.md` after the recovery records/configuration are reviewed on main.
|
||||
Keep Jenkins and the remote delivery node available. Production approval requires an authorized
|
||||
human; an agent must not approve unattended.
|
||||
|
||||
|
||||
+15
-16
@@ -2,20 +2,15 @@
|
||||
|
||||
These are execution instructions, not completed release evidence.
|
||||
|
||||
Current status, 15 November 2026: Billy's DNS records resolve correctly and the
|
||||
Current status, 15 November 2026 Eastern / 16 November UTC: Billy's DNS records resolve correctly and the
|
||||
two Caddy routes are active with trusted certificates and HTTP-to-HTTPS redirects.
|
||||
502 is expected for production while its backend is absent. The one-time HTTPS helper
|
||||
has already run; use the normal validate/reload procedure for later changes.
|
||||
The reviewed preparation is merged, the release job is enabled, and real
|
||||
Jenkins test/secret blocks are recorded. Release build 3 published v1 but
|
||||
stopped at Ansible's PTY request before any app change. PR 25's SSH correction
|
||||
is merged; build 4 passed initial staging checks, but its unchanged rerun was
|
||||
blocked by Docker's three-second health timeout. The ten-second diagnostic
|
||||
passed eight checks under identical limits. Review the health correction and
|
||||
separate v2 source/test change as two commits in one PR; use a merge commit
|
||||
to retain both SHAs. Select the first for v1 and the second for v2. Neither
|
||||
version is approved for production yet.
|
||||
Monitoring additions and successful releases remain pending.
|
||||
The one-time HTTPS helper has already run; use the normal validate/reload
|
||||
procedure for later changes. PRs 24–26 are merged. Actual builds 5/6 passed
|
||||
v1/v2 promotions, zero-change reruns and real vsun1 approvals. Both environments
|
||||
are healthy v2. The production probe/panel is applied and verified; one HTTP 502
|
||||
sample during replacement is recorded. Review the four actual successful
|
||||
records and staging-only fault/revert history before recovery; see
|
||||
`exercises/README.md`. The earlier failed builds remain historical evidence.
|
||||
|
||||
## Authority and preparation
|
||||
|
||||
@@ -40,9 +35,13 @@ docker exec gitea-caddy-1 caddy reload --config /etc/caddy/Caddyfile --adapter c
|
||||
docker exec monitoring-prometheus-1 promtool check config /etc/prometheus/prometheus.yml
|
||||
```
|
||||
|
||||
Preserve bind-mounted file inodes when copying new contents. Apply monitoring
|
||||
only after healthy production, then reload using its existing documented
|
||||
procedure. The temporary candidate checks already passed without a reload.
|
||||
Preserve bind-mounted file inodes when copying new contents. Monitoring was
|
||||
applied only after healthy v1 production, using the guarded one-time
|
||||
`bootstrap/enable-production-monitoring.py`. It compares prior probes/panels,
|
||||
validates with promtool, backs up and reloads Prometheus via SIGHUP. Do not
|
||||
rerun its one-time application over the already changed state. The protected
|
||||
backup is `/root/ssw590-delivery-bootstrap/monitoring-20261116/`. Actual targets,
|
||||
reload metric and the provisioned Grafana panel were verified separately.
|
||||
|
||||
## v1 and v2
|
||||
|
||||
|
||||
@@ -0,0 +1,79 @@
|
||||
"""Apply the reviewed production probe/panel only after production is healthy."""
|
||||
import argparse
|
||||
from datetime import datetime, timezone
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
import shutil
|
||||
import subprocess
|
||||
import urllib.request
|
||||
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument('--prometheus', required=True, type=Path)
|
||||
parser.add_argument('--dashboard', required=True, type=Path)
|
||||
parser.add_argument('--backup', required=True, type=Path)
|
||||
parser.add_argument('--apply', action='store_true')
|
||||
args = parser.parse_args()
|
||||
live_prom = Path('/root/monitoring/prometheus/prometheus.yml')
|
||||
live_dashboard = Path('/root/monitoring/grafana/dashboards/sre.json')
|
||||
before = {live_prom:live_prom.read_bytes(), live_dashboard:live_dashboard.read_bytes()}
|
||||
candidate_prom = args.prometheus.read_text().replace('\r\n','\n')
|
||||
candidate_dashboard = args.dashboard.read_bytes()
|
||||
addition = ' # Apply this addition only after Assignment 8 production is healthy.\n - https://app.yebilly.me/health\n'
|
||||
assert candidate_prom.count(addition) == 1, 'Unexpected production probe'
|
||||
assert candidate_prom.replace(addition,'').strip() == before[live_prom].decode().replace('\r\n','\n').strip(), 'Existing probes differ; inspect before changing'
|
||||
old = json.loads(before[live_dashboard])
|
||||
new = json.loads(candidate_dashboard)
|
||||
assert old['uid'] == new['uid'] == 'group1-sre'
|
||||
assert old['version'] == 1 and new['version'] == 2
|
||||
panel = new['panels'][-1]
|
||||
assert panel['id'] == 8 and panel['type'] == 'timeseries'
|
||||
assert panel['targets'][0]['expr'] == 'probe_success{job="https",instance="https://app.yebilly.me/health"}'
|
||||
comparison = dict(new, version=old['version'], panels=new['panels'][:-1])
|
||||
assert comparison == old, 'Existing dashboard differs; inspect before changing'
|
||||
with urllib.request.urlopen('https://app.yebilly.me/health',timeout=10) as response:
|
||||
health = json.load(response)
|
||||
assert response.status == 200 and health['status'] == 'ok' and health['version'] in {'v1','v2'}, 'Production must be healthy first'
|
||||
|
||||
stamp = datetime.now(timezone.utc).strftime('%Y%m%dT%H%M%S%fZ')
|
||||
temporary = '/tmp/ssw590-production-probe-' + stamp + '.yml'
|
||||
subprocess.run(['docker','cp',str(args.prometheus),'monitoring-prometheus-1:'+temporary],check=True,capture_output=True)
|
||||
try:
|
||||
validation = subprocess.check_output(['docker','exec','monitoring-prometheus-1','promtool','check','config',temporary],text=True)
|
||||
if not args.apply:
|
||||
print(validation + 'Validated only; no active file changed.')
|
||||
raise SystemExit(0)
|
||||
args.backup.mkdir(parents=True,mode=0o700,exist_ok=False)
|
||||
for path in before:
|
||||
shutil.copy2(path,args.backup / (path.name + '.before'))
|
||||
inodes = {p:p.stat().st_ino for p in before}
|
||||
|
||||
def write(path,content):
|
||||
with path.open('wb') as stream:
|
||||
stream.write(content)
|
||||
stream.flush()
|
||||
os.fsync(stream.fileno())
|
||||
assert path.stat().st_ino == inodes[path], 'Bind inode changed'
|
||||
|
||||
try:
|
||||
write(live_prom,candidate_prom.encode())
|
||||
write(live_dashboard,candidate_dashboard)
|
||||
subprocess.run(['docker','kill','--signal','HUP','monitoring-prometheus-1'],check=True,capture_output=True)
|
||||
except Exception:
|
||||
for path,content in before.items():
|
||||
write(path,content)
|
||||
subprocess.run(['docker','kill','--signal','HUP','monitoring-prometheus-1'],check=True,capture_output=True)
|
||||
raise
|
||||
report = {'applied_at':datetime.now(timezone.utc).isoformat(),'production_health':health,
|
||||
'validation':validation,'prior_probes_and_panels_preserved':True,
|
||||
'files':[{'path':str(p),'before_sha256':hashlib.sha256(before[p]).hexdigest(),
|
||||
'after_sha256':hashlib.sha256(p.read_bytes()).hexdigest(),
|
||||
'inode_preserved':p.stat().st_ino == inodes[p]} for p in before],
|
||||
'backup':str(args.backup),'reload':'Prometheus SIGHUP; Grafana file provisioning',
|
||||
'result':'applied; runtime probe and panel verification still required'}
|
||||
(args.backup / 'applied.json').write_text(json.dumps(report,indent=2))
|
||||
print(json.dumps(report,indent=2))
|
||||
finally:
|
||||
# docker cp creates a root-owned file; the Prometheus service runs as nobody.
|
||||
subprocess.run(['docker','exec','--user','0','monitoring-prometheus-1','rm','-f',temporary],check=True,capture_output=True)
|
||||
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"applied_at": "2026-11-16T03:08:11.087796+00:00",
|
||||
"production_health": {
|
||||
"status": "ok",
|
||||
"version": "v1"
|
||||
},
|
||||
"validation": "Checking /tmp/ssw590-production-probe-20261116T030810544427Z.yml\n SUCCESS: /tmp/ssw590-production-probe-20261116T030810544427Z.yml is valid prometheus config file syntax\n\n",
|
||||
"prior_probes_and_panels_preserved": true,
|
||||
"files": [
|
||||
{
|
||||
"path": "/root/monitoring/prometheus/prometheus.yml",
|
||||
"before_sha256": "fe1d0f479d947e20ea7ebfec164689fe69ea9539ba0289adc2b7d26b8ffe62d6",
|
||||
"after_sha256": "e35bc7fb3d09f7b3442324a2af147d8f1319ae1f0631ba81ed7577bb63826edd",
|
||||
"inode_preserved": true
|
||||
},
|
||||
{
|
||||
"path": "/root/monitoring/grafana/dashboards/sre.json",
|
||||
"before_sha256": "c21fadca47ee624001133a82b788e728d08168664302666ed103113f3bec5f13",
|
||||
"after_sha256": "08f99b845e5d56b81f54bf1b386aa50a54a88296ce5caf9496c5bfbf62929ed1",
|
||||
"inode_preserved": true
|
||||
}
|
||||
],
|
||||
"backup": "/root/ssw590-delivery-bootstrap/monitoring-20261116",
|
||||
"reload": "Prometheus SIGHUP; Grafana file provisioning",
|
||||
"result": "applied; runtime probe and panel verification still required"
|
||||
}
|
||||
@@ -0,0 +1,218 @@
|
||||
{
|
||||
"observed_at": "2026-11-16T03:14:11.206493+00:00",
|
||||
"queries": {
|
||||
"probe_success{job=\"https\"}": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_success",
|
||||
"instance": "https://ci.yebilly.me/login",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.242,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_success",
|
||||
"instance": "https://git.yebilly.me/user/login",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.242,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_success",
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.242,
|
||||
"1"
|
||||
]
|
||||
}
|
||||
],
|
||||
"prometheus_config_last_reload_successful": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "prometheus_config_last_reload_successful",
|
||||
"instance": "prometheus:9090",
|
||||
"job": "prometheus"
|
||||
},
|
||||
"value": [
|
||||
1794798851.244,
|
||||
"1"
|
||||
]
|
||||
}
|
||||
],
|
||||
"up": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "blackbox-exporter:9115",
|
||||
"job": "blackbox"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "prometheus:9090",
|
||||
"job": "prometheus"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "https://ci.yebilly.me/login",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "https://git.yebilly.me/user/login",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "node-exporter:9100",
|
||||
"job": "node"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
},
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "up",
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"value": [
|
||||
1794798851.245,
|
||||
"1"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"targets": [
|
||||
{
|
||||
"labels": {
|
||||
"instance": "blackbox-exporter:9115",
|
||||
"job": "blackbox"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:13:46.738098436Z"
|
||||
},
|
||||
{
|
||||
"labels": {
|
||||
"instance": "https://git.yebilly.me/user/login",
|
||||
"job": "https"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:14:02.878212313Z"
|
||||
},
|
||||
{
|
||||
"labels": {
|
||||
"instance": "https://ci.yebilly.me/login",
|
||||
"job": "https"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:13:50.769303819Z"
|
||||
},
|
||||
{
|
||||
"labels": {
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:13:54.602557327Z"
|
||||
},
|
||||
{
|
||||
"labels": {
|
||||
"instance": "node-exporter:9100",
|
||||
"job": "node"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:14:06.522911829Z"
|
||||
},
|
||||
{
|
||||
"labels": {
|
||||
"instance": "prometheus:9090",
|
||||
"job": "prometheus"
|
||||
},
|
||||
"health": "up",
|
||||
"lastError": "",
|
||||
"lastScrape": "2026-11-16T03:13:47.742950331Z"
|
||||
}
|
||||
],
|
||||
"dashboard_provisioning_source": {
|
||||
"uid": "group1-sre",
|
||||
"title": "Group 1 SRE",
|
||||
"panels": [
|
||||
{
|
||||
"id": 1,
|
||||
"title": "Droplet CPU utilization (%)"
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"title": "Available memory (bytes)"
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"title": "Root filesystem available (%)"
|
||||
},
|
||||
{
|
||||
"id": 4,
|
||||
"title": "Gitea HTTPS availability (probe_success)"
|
||||
},
|
||||
{
|
||||
"id": 5,
|
||||
"title": "Jenkins HTTPS availability (probe_success)"
|
||||
},
|
||||
{
|
||||
"id": 6,
|
||||
"title": "HTTPS probe duration (s)"
|
||||
},
|
||||
{
|
||||
"id": 7,
|
||||
"title": "Scrape health (up)"
|
||||
},
|
||||
{
|
||||
"id": 8,
|
||||
"title": "Pricing production HTTPS availability (probe_success)"
|
||||
}
|
||||
]
|
||||
},
|
||||
"production_probe_up": true,
|
||||
"pricing_panel_configured": true,
|
||||
"runtime_panel_verification": "Separate Grafana UI verification required"
|
||||
}
|
||||
@@ -0,0 +1,202 @@
|
||||
{
|
||||
"releases": [
|
||||
{
|
||||
"version": "v1",
|
||||
"build": 5,
|
||||
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||
"result": "SUCCESS",
|
||||
"source": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"started": "2026-11-16T03:00:10.966000+00:00",
|
||||
"completed": "2026-11-16T03:05:08.180000+00:00",
|
||||
"total_seconds": 297.214,
|
||||
"approval": {
|
||||
"Approver": "vsun1",
|
||||
"Decision": "approved",
|
||||
"UTC": "2026-11-16T03:04:01Z"
|
||||
},
|
||||
"deployments": {
|
||||
"staging-deploy": {
|
||||
"started": "2026-11-16T03:01:27.245015+00:00",
|
||||
"completed": "2026-11-16T03:02:26.405414+00:00",
|
||||
"elapsed_seconds": 59.16,
|
||||
"operation": "deploy",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 3,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
},
|
||||
"staging-rerun": {
|
||||
"started": "2026-11-16T03:02:29.440969+00:00",
|
||||
"completed": "2026-11-16T03:03:10.939985+00:00",
|
||||
"elapsed_seconds": 41.499,
|
||||
"operation": "rerun",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 0,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
},
|
||||
"production-deploy": {
|
||||
"started": "2026-11-16T03:04:05.207821+00:00",
|
||||
"completed": "2026-11-16T03:05:05.610689+00:00",
|
||||
"elapsed_seconds": 60.403,
|
||||
"operation": "deploy",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 4,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
}
|
||||
},
|
||||
"scans": {
|
||||
"image-gate": {
|
||||
"analyzed_targets": 2,
|
||||
"high_critical": 0,
|
||||
"report_sha256": "55ca73c4b493fa7a612671e02e6cf097c0b3fc011895712189704c8721b9028e"
|
||||
},
|
||||
"published-image-gate": {
|
||||
"analyzed_targets": 2,
|
||||
"high_critical": 0,
|
||||
"report_sha256": "f375643ae8f6888e9f5ab582342c4d11bee8563936c86a9de08e7b7b5cd52ef8"
|
||||
},
|
||||
"dependencies": {
|
||||
"packages": 9,
|
||||
"advisories": 0
|
||||
},
|
||||
"source_secrets": {
|
||||
"findings": 0
|
||||
}
|
||||
},
|
||||
"unit_tests": {
|
||||
"started": "2026-11-16T03:00:34.908112+00:00",
|
||||
"completed": "2026-11-16T03:00:35.815417+00:00",
|
||||
"exit_code": 0,
|
||||
"result": "passed"
|
||||
},
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"records": [
|
||||
"delivery/releases/v1-staging.json",
|
||||
"delivery/releases/v1-production.json"
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "v2",
|
||||
"build": 6,
|
||||
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||
"result": "SUCCESS",
|
||||
"source": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"started": "2026-11-16T03:05:33.456000+00:00",
|
||||
"completed": "2026-11-16T03:12:29.163000+00:00",
|
||||
"total_seconds": 415.707,
|
||||
"approval": {
|
||||
"Approver": "vsun1",
|
||||
"Decision": "approved",
|
||||
"UTC": "2026-11-16T03:11:18Z"
|
||||
},
|
||||
"deployments": {
|
||||
"staging-deploy": {
|
||||
"started": "2026-11-16T03:06:46.416545+00:00",
|
||||
"completed": "2026-11-16T03:07:46.522813+00:00",
|
||||
"elapsed_seconds": 60.106,
|
||||
"operation": "deploy",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 3,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
},
|
||||
"staging-rerun": {
|
||||
"started": "2026-11-16T03:07:49.044973+00:00",
|
||||
"completed": "2026-11-16T03:08:34.532184+00:00",
|
||||
"elapsed_seconds": 45.487,
|
||||
"operation": "rerun",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 0,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
},
|
||||
"production-deploy": {
|
||||
"started": "2026-11-16T03:11:21.802336+00:00",
|
||||
"completed": "2026-11-16T03:12:28.036700+00:00",
|
||||
"elapsed_seconds": 66.234,
|
||||
"operation": "deploy",
|
||||
"ansible_exit_code": 0,
|
||||
"recaps": [
|
||||
{
|
||||
"host": "startup",
|
||||
"ok": 10,
|
||||
"changed": 3,
|
||||
"unreachable": 0,
|
||||
"failed": 0
|
||||
}
|
||||
],
|
||||
"result": "passed"
|
||||
}
|
||||
},
|
||||
"scans": {
|
||||
"image-gate": {
|
||||
"analyzed_targets": 2,
|
||||
"high_critical": 0,
|
||||
"report_sha256": "89d8912330a8fdfb0e5e8ccd1e41f971415c611ba80ee2dd6d484401ec2f6a09"
|
||||
},
|
||||
"published-image-gate": {
|
||||
"analyzed_targets": 2,
|
||||
"high_critical": 0,
|
||||
"report_sha256": "32562513adffdd78782417083b51e56fd29f758a3e050faeda147dee822bc339"
|
||||
},
|
||||
"dependencies": {
|
||||
"packages": 9,
|
||||
"advisories": 0
|
||||
},
|
||||
"source_secrets": {
|
||||
"findings": 0
|
||||
}
|
||||
},
|
||||
"unit_tests": {
|
||||
"started": "2026-11-16T03:05:54.830225+00:00",
|
||||
"completed": "2026-11-16T03:05:55.609726+00:00",
|
||||
"exit_code": 0,
|
||||
"result": "passed"
|
||||
},
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"records": [
|
||||
"delivery/releases/v2-staging.json",
|
||||
"delivery/releases/v2-production.json"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,85 @@
|
||||
# Reviewed v1/v2 releases and production monitoring
|
||||
|
||||
Client date: 15 November 2026 Eastern; all times below are 16 November UTC.
|
||||
Billy approved PR 26 at 02:56:00; Vincent merged it at 02:57:42 as
|
||||
`231d11528a425114a8d3570afba56943c4d57d96`, preserving both source commits.
|
||||
The merge-triggered manual workflow 15 passed in 2m7s before delivery began.
|
||||
|
||||
| Evidence | v1 | v2 |
|
||||
|---|---|---|
|
||||
| Source and configuration | `34f26e6948b7001ede8ca19f23b67a02082e6a9a` | `6bddbfba5a36e0e397537678ffb197e101fb0670` |
|
||||
| Jenkins | [Build 5 SUCCESS](https://ci.yebilly.me/job/secure-delivery/job/pricing/5/) | [Build 6 SUCCESS](https://ci.yebilly.me/job/secure-delivery/job/pricing/6/) |
|
||||
| Full run, including human wait | 03:00:10.966–03:05:08.180; 297.214 s | 03:05:33.456–03:12:29.163; 415.707 s |
|
||||
| Initial staging | 59.160 s; ok=10, changed=3, failed=0 | 60.106 s; ok=10, changed=3, failed=0 |
|
||||
| Unchanged staging rerun | 41.499 s; ok=10, changed=0, failed=0 | 45.487 s; ok=10, changed=0, failed=0 |
|
||||
| Actual human approval | `vsun1`, 03:04:01 | `vsun1`, 03:11:18 |
|
||||
| Production deployment | 03:04:05.208–03:05:05.611; 60.403 s | 03:11:21.802–03:12:28.037; 66.234 s |
|
||||
| Verified quantity 3 total | USD 30 in both environments | USD 36 in both environments |
|
||||
|
||||
Both runs passed twelve control tests and three Flask tests, clean-source
|
||||
scanning, all nine locked dependency audits (zero advisories), and pre-push and
|
||||
registry-digest image gates (two analyzed targets, zero HIGH/CRITICAL findings).
|
||||
No exception was added. Each source-SHA image was built once, pushed, pulled
|
||||
and promoted by the same exact digest across staging and production.
|
||||
|
||||
Repository: `git.yebilly.me/ssw590-group1/pricing`
|
||||
|
||||
```text
|
||||
v1 sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8
|
||||
v2 sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b
|
||||
```
|
||||
|
||||
The four selectors in `delivery/releases/` are copied unchanged from these
|
||||
successful Jenkins builds. They include the real source/configuration SHAs,
|
||||
digest, environment, expected version/total, build URL and creation time.
|
||||
They pass `release.py verify` and need review/commit before recovery. Earlier
|
||||
failed-attempt records were not substituted. Full reports and actual approval
|
||||
records remain archived in Jenkins; exact local copies are retained in ignored
|
||||
`build/evidence/assignment8-execution/jenkins-{5,6}/`.
|
||||
[Machine-readable summary](releases-20261115.json) includes recaps, timestamps,
|
||||
scan counts and full image-report SHA-256 hashes.
|
||||
|
||||
## Production monitoring, applied only after healthy v1
|
||||
|
||||
At 03:08:11 the previously reviewed production `/health` target and panel 8
|
||||
were applied. The guarded helper required healthy production, compared earlier
|
||||
probes/panels, validated the candidate with installed promtool, saved protected
|
||||
backups and preserved both bind-mounted file inodes. Prometheus reloaded via
|
||||
SIGHUP; Grafana provisioned the changed file. No container, volume, retention,
|
||||
allowlist, credential or existing alert rule was replaced. The first dry-run
|
||||
cleanup needed root inside Prometheus because docker cp created a root-owned
|
||||
temporary file; that was corrected before active application.
|
||||
|
||||
[Applied metadata](monitoring-applied-20261115.json) records hashes and backup
|
||||
`/root/ssw590-delivery-bootstrap/monitoring-20261116/`.
|
||||
[Actual samples and targets](monitoring-runtime-20261115.json), observed at
|
||||
03:14:11, showed production, Gitea and Jenkins probe_success=1, all six scrape
|
||||
targets up and successful reload=1. The dashboard source retained its previous
|
||||
seven panels; the actual Grafana UI also displayed the new pricing panel and
|
||||
its data. A legacy SQL dashboard lookup returned no row, so it was not used
|
||||
as proof of provisioning.
|
||||
|
||||
Prometheus supports [runtime SIGHUP reload](https://prometheus.io/docs/prometheus/latest/configuration/configuration/).
|
||||
Grafana's [file provisioning](https://grafana.com/docs/grafana/latest/administration/provisioning/)
|
||||
detects dashboard changes; visible runtime verification was performed separately.
|
||||
|
||||
## Observed availability during v2 promotion
|
||||
|
||||
The [post-release capture](runtime-20261115.json) at 03:28:08 verified both
|
||||
environments as healthy v2 with the exact source SHA, HTTP 200 for identity,
|
||||
health and total 36, and HTTP 400 for quantity 0. Both containers had zero OOM
|
||||
events and no observed memory-limit events in that capture.
|
||||
|
||||
The production probe history contains one failed sample at **03:11:54.602**
|
||||
during v2's 03:11:21.802–03:12:28.037 deployment window. Adjacent successful
|
||||
samples were 03:11:24.602 and 03:12:24.602. The capture preserves exact HTTP
|
||||
status and duration samples. A single failed 30-second-cadence sample does
|
||||
not establish an exact 30-second outage or zero downtime between other samples.
|
||||
The interval is shorter than the existing one-minute alert duration; no alert
|
||||
firing or notification is claimed without separate evidence. The single-host
|
||||
Compose replacement is not blue/green or highly available deployment.
|
||||
|
||||
The Grafana screenshot is retained in the manual's image folder. Production
|
||||
rollback and deliberate staging failure/recovery remain **unexecuted** pending
|
||||
review of the successful records and preserved staging-only configuration fault.
|
||||
See [the recovery exercise instructions](../exercises/README.md).
|
||||
@@ -0,0 +1,604 @@
|
||||
{
|
||||
"observed_at": "2026-11-16T03:28:08.004273+00:00",
|
||||
"endpoints": {
|
||||
"staging": [
|
||||
{
|
||||
"path": "/",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"service": "Startup Pricing",
|
||||
"version": "v2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/health",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"status": "ok",
|
||||
"version": "v2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/price?quantity=3",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"currency": "USD",
|
||||
"quantity": 3,
|
||||
"total": 36
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/price?quantity=0",
|
||||
"http_status": 400,
|
||||
"body": {
|
||||
"error": "quantity must be between 1 and 1000"
|
||||
}
|
||||
}
|
||||
],
|
||||
"production": [
|
||||
{
|
||||
"path": "/",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"service": "Startup Pricing",
|
||||
"version": "v2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/health",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"status": "ok",
|
||||
"version": "v2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/price?quantity=3",
|
||||
"http_status": 200,
|
||||
"body": {
|
||||
"currency": "USD",
|
||||
"quantity": 3,
|
||||
"total": 36
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "/price?quantity=0",
|
||||
"http_status": 400,
|
||||
"body": {
|
||||
"error": "quantity must be between 1 and 1000"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"containers": {
|
||||
"staging": {
|
||||
"running": true,
|
||||
"oom_killed": false,
|
||||
"health": "healthy",
|
||||
"memory_events": "low 0\nhigh 0\nmax 0\noom 0\noom_kill 0\noom_group_kill 0\n"
|
||||
},
|
||||
"production": {
|
||||
"running": true,
|
||||
"oom_killed": false,
|
||||
"health": "healthy",
|
||||
"memory_events": "low 0\nhigh 0\nmax 0\noom 0\noom_kill 0\noom_group_kill 0\n"
|
||||
}
|
||||
},
|
||||
"monitoring_samples": {
|
||||
"probe_success": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_success",
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"values": [
|
||||
[
|
||||
1794798504.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798534.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798564.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798594.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798624.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798654.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798684.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798714.602,
|
||||
"0"
|
||||
],
|
||||
[
|
||||
1794798744.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798774.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798804.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798834.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798864.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798894.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798924.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798954.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794798984.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799014.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799044.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799074.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799104.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799134.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799164.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799194.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799224.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799254.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799284.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799314.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799344.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799374.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799404.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799434.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799464.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799494.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799524.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799554.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799584.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799614.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799644.602,
|
||||
"1"
|
||||
],
|
||||
[
|
||||
1794799674.602,
|
||||
"1"
|
||||
]
|
||||
]
|
||||
}
|
||||
],
|
||||
"probe_http_status_code": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_http_status_code",
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"values": [
|
||||
[
|
||||
1794798504.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798534.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798564.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798594.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798624.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798654.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798684.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798714.602,
|
||||
"502"
|
||||
],
|
||||
[
|
||||
1794798744.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798774.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798804.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798834.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798864.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798894.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798924.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798954.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794798984.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799014.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799044.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799074.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799104.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799134.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799164.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799194.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799224.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799254.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799284.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799314.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799344.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799374.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799404.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799434.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799464.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799494.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799524.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799554.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799584.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799614.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799644.602,
|
||||
"200"
|
||||
],
|
||||
[
|
||||
1794799674.602,
|
||||
"200"
|
||||
]
|
||||
]
|
||||
}
|
||||
],
|
||||
"probe_duration_seconds": [
|
||||
{
|
||||
"metric": {
|
||||
"__name__": "probe_duration_seconds",
|
||||
"instance": "https://app.yebilly.me/health",
|
||||
"job": "https"
|
||||
},
|
||||
"values": [
|
||||
[
|
||||
1794798504.602,
|
||||
"0.057399797"
|
||||
],
|
||||
[
|
||||
1794798534.602,
|
||||
"0.028300941"
|
||||
],
|
||||
[
|
||||
1794798564.602,
|
||||
"0.023132207"
|
||||
],
|
||||
[
|
||||
1794798594.602,
|
||||
"0.021246711"
|
||||
],
|
||||
[
|
||||
1794798624.602,
|
||||
"0.023551593"
|
||||
],
|
||||
[
|
||||
1794798654.602,
|
||||
"0.023607454"
|
||||
],
|
||||
[
|
||||
1794798684.602,
|
||||
"0.182590187"
|
||||
],
|
||||
[
|
||||
1794798714.602,
|
||||
"0.080492206"
|
||||
],
|
||||
[
|
||||
1794798744.602,
|
||||
"0.048286408"
|
||||
],
|
||||
[
|
||||
1794798774.602,
|
||||
"0.021541103"
|
||||
],
|
||||
[
|
||||
1794798804.602,
|
||||
"0.082225976"
|
||||
],
|
||||
[
|
||||
1794798834.602,
|
||||
"0.026266413"
|
||||
],
|
||||
[
|
||||
1794798864.602,
|
||||
"0.021229488"
|
||||
],
|
||||
[
|
||||
1794798894.602,
|
||||
"0.026039405"
|
||||
],
|
||||
[
|
||||
1794798924.602,
|
||||
"0.024995092"
|
||||
],
|
||||
[
|
||||
1794798954.602,
|
||||
"0.026780972"
|
||||
],
|
||||
[
|
||||
1794798984.602,
|
||||
"0.022616423"
|
||||
],
|
||||
[
|
||||
1794799014.602,
|
||||
"0.079699801"
|
||||
],
|
||||
[
|
||||
1794799044.602,
|
||||
"0.023901787"
|
||||
],
|
||||
[
|
||||
1794799074.602,
|
||||
"0.029992619"
|
||||
],
|
||||
[
|
||||
1794799104.602,
|
||||
"0.022638427"
|
||||
],
|
||||
[
|
||||
1794799134.602,
|
||||
"0.082084913"
|
||||
],
|
||||
[
|
||||
1794799164.602,
|
||||
"0.03257138"
|
||||
],
|
||||
[
|
||||
1794799194.602,
|
||||
"0.028129282"
|
||||
],
|
||||
[
|
||||
1794799224.602,
|
||||
"0.02010407"
|
||||
],
|
||||
[
|
||||
1794799254.602,
|
||||
"0.081311747"
|
||||
],
|
||||
[
|
||||
1794799284.602,
|
||||
"0.027378471"
|
||||
],
|
||||
[
|
||||
1794799314.602,
|
||||
"0.020048075"
|
||||
],
|
||||
[
|
||||
1794799344.602,
|
||||
"0.018652785"
|
||||
],
|
||||
[
|
||||
1794799374.602,
|
||||
"0.019703541"
|
||||
],
|
||||
[
|
||||
1794799404.602,
|
||||
"0.020952708"
|
||||
],
|
||||
[
|
||||
1794799434.602,
|
||||
"0.020200855"
|
||||
],
|
||||
[
|
||||
1794799464.602,
|
||||
"0.081365277"
|
||||
],
|
||||
[
|
||||
1794799494.602,
|
||||
"0.030027777"
|
||||
],
|
||||
[
|
||||
1794799524.602,
|
||||
"0.020230579"
|
||||
],
|
||||
[
|
||||
1794799554.602,
|
||||
"0.028499939"
|
||||
],
|
||||
[
|
||||
1794799584.602,
|
||||
"0.024388546"
|
||||
],
|
||||
[
|
||||
1794799614.602,
|
||||
"0.02259808"
|
||||
],
|
||||
[
|
||||
1794799644.602,
|
||||
"0.030377942"
|
||||
],
|
||||
[
|
||||
1794799674.602,
|
||||
"0.080982268"
|
||||
]
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
# Reviewed recovery exercises
|
||||
|
||||
V1 and v2 have now completed Jenkins releases 5 and 6 with real human approvals.
|
||||
The four exact successful records in `../releases/` need review/commit before
|
||||
recovery. Do not use the earlier failed attempts' records.
|
||||
|
||||
The patch here is a deliberate **staging-only** configuration fault: Gunicorn
|
||||
binds to 8001 while the unchanged image healthcheck probes 8000. It changes no
|
||||
image, host port, credential, shared service, production command or stored data.
|
||||
The reviewed Jenkins `staging-failure` mode requires a staging record and uses
|
||||
that record's existing v2 digest; it does not publish/rebuild an image.
|
||||
|
||||
## Commit and review sequence
|
||||
|
||||
1. Commit the actual release records, evidence, monitoring helper, manual and
|
||||
this patch while the active template remains correct.
|
||||
2. Apply this patch and commit the one changed template as
|
||||
`Exercise staging-only Gunicorn bind mismatch`.
|
||||
3. Immediately revert that second commit, creating a third commit. The final
|
||||
branch/main template must be good; the bad configuration survives only as
|
||||
a reviewed historical commit selected explicitly by SHA for the exercise.
|
||||
4. Billy reviews all three commits, including the intermediate configuration
|
||||
fault and its restoration. Use a merge commit, preserving history.
|
||||
|
||||
After the first commit, the two configuration commits can be made with:
|
||||
|
||||
```powershell
|
||||
git apply delivery/exercises/staging-bind-mismatch.patch
|
||||
git add delivery/ansible/templates/compose.yaml.j2
|
||||
git commit -m "Exercise staging-only Gunicorn bind mismatch"
|
||||
git revert --no-edit HEAD
|
||||
```
|
||||
|
||||
## Execution after review/merge
|
||||
|
||||
First record the planned healthy production rollback decision and start the
|
||||
HTTPS observer. Use `MODE=rollback-production` and
|
||||
`RELEASE_RECORD=delivery/releases/v1-production.json`. The approved operation
|
||||
must restore v1's exact image/configuration, source SHA and total 30. This is
|
||||
an exercise on healthy v2, not a claimed production incident. A real human
|
||||
must approve the Jenkins production input.
|
||||
|
||||
Then start a separate staging observer and select:
|
||||
|
||||
```text
|
||||
MODE=staging-failure
|
||||
RELEASE_RECORD=delivery/releases/v2-staging.json
|
||||
STAGING_FAILURE_CONFIG=<full SHA of the reviewed bind-mismatch commit>
|
||||
```
|
||||
|
||||
The SHA must be the actual preserved intermediate commit, not the final
|
||||
revert or an invented placeholder. Leave SOURCE_COMMIT blank so the job uses
|
||||
reviewed current main for its control code. Compose wait must block within
|
||||
its 90-second bound and stop before production. Preserve that failure.
|
||||
|
||||
Recover with `MODE=recover-staging` and the same good v2 staging record, leaving
|
||||
STAGING_FAILURE_CONFIG blank. It must restore the recorded good configuration,
|
||||
verify source/version/total 36, and pass the unchanged rerun with changed=0.
|
||||
Save decision/start/completion times, recaps, observer samples and monitoring
|
||||
correlation. Samples cannot establish zero interruption between requests.
|
||||
|
||||
Both exercises remain unexecuted. No failure configuration is deployed merely
|
||||
by merging this PR: its net template is unchanged and the bad SHA is selected
|
||||
only in the explicit staging exercise.
|
||||
@@ -0,0 +1,13 @@
|
||||
diff --git a/delivery/ansible/templates/compose.yaml.j2 b/delivery/ansible/templates/compose.yaml.j2
|
||||
--- a/delivery/ansible/templates/compose.yaml.j2
|
||||
+++ b/delivery/ansible/templates/compose.yaml.j2
|
||||
@@ -1,6 +1,9 @@
|
||||
services:
|
||||
app:
|
||||
image: "{{ release_image }}"
|
||||
+{% if target_env == 'staging' %}
|
||||
+ command: ["gunicorn", "--bind", "0.0.0.0:8001", "--workers", "1", "--worker-tmp-dir", "/tmp", "app:app"]
|
||||
+{% endif %}
|
||||
restart: unless-stopped
|
||||
read_only: true
|
||||
tmpfs:
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||
"expected_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"expected_version": "v1",
|
||||
"expected_total": 30,
|
||||
"proxy_network": "gitea_web",
|
||||
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||
"created_at": "2026-11-16T03:01:23.246375+00:00",
|
||||
"target_env": "production",
|
||||
"public_url": "https://app.yebilly.me"
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||
"expected_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||
"expected_version": "v1",
|
||||
"expected_total": 30,
|
||||
"proxy_network": "gitea_web",
|
||||
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||
"created_at": "2026-11-16T03:01:23.246375+00:00",
|
||||
"target_env": "staging",
|
||||
"public_url": "https://staging.yebilly.me"
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"expected_version": "v2",
|
||||
"expected_total": 36,
|
||||
"proxy_network": "gitea_web",
|
||||
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||
"target_env": "production",
|
||||
"public_url": "https://app.yebilly.me"
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||
"expected_version": "v2",
|
||||
"expected_total": 36,
|
||||
"proxy_network": "gitea_web",
|
||||
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||
"target_env": "staging",
|
||||
"public_url": "https://staging.yebilly.me"
|
||||
}
|
||||
Reference in New Issue
Block a user