diff --git a/.gitignore b/.gitignore index a1b95c2..eb88664 100644 --- a/.gitignore +++ b/.gitignore @@ -14,6 +14,8 @@ # Intermediate documents and automatic conversions *.dvi +# This exact upstream asset is part of the frozen, hash-verified demo input. +!/demo/tikzrefinery/documents/assets/loop-example/loop-boxes.dvi *.xdv *-converted-to.* diff --git a/demo/Jenkinsfile b/demo/Jenkinsfile index 54c8869..69c66ce 100644 --- a/demo/Jenkinsfile +++ b/demo/Jenkinsfile @@ -12,7 +12,7 @@ pipeline { steps { sh 'python3 demo/ci/reset-output.py' sh 'git merge-base --is-ancestor HEAD origin/main' - sh 'python3 demo/ci/verify-snapshot.py' + sh 'python3 demo/ci/verify-snapshot.py --require-tracked' } } stage('Build application and test provider') { @@ -30,9 +30,9 @@ pipeline { } post { always { - junit testResults: 'build/demo/reports/tests.xml', allowEmptyResults: true archiveArtifacts artifacts: 'build/demo/artifacts/*,build/demo/reports/*', allowEmptyArchive: true, fingerprint: true + junit testResults: 'build/demo/reports/tests.xml', allowEmptyResults: true } } } diff --git a/demo/README.md b/demo/README.md index 619bae0..fb950e4 100644 --- a/demo/README.md +++ b/demo/README.md @@ -10,7 +10,11 @@ project-wide licence is granted by this import. `snapshot.json` records all 435 original Git blob IDs, SHA-256 hashes and sizes. `tikzrefinery/` contains raw committed blobs, not the senior checkout's untracked work or old package binaries. Git attributes preserve those bytes on Windows -and Linux. Run `python demo/ci/verify-snapshot.py` before and after a build. +and Linux. Run `python demo/ci/verify-snapshot.py --require-tracked` from a Git +checkout before and after a build. This checks the index as well as the files on +disk, so an ignored but locally present upstream asset cannot hide an incomplete +commit. Stage intended snapshot files before using that check. Exported SSH +rehearsals without Git metadata can use the command without `--require-tracked`. Do not regenerate canonical PDFs or change product source during baseline verification. The proposed provider-class naming correction remains reserved for a separate @@ -130,6 +134,16 @@ JUnit display, artifact archiving/download and the corresponding source/version identity. Publish the reviewed baseline before selecting it in a job. The provider rename remains pending until that verification succeeds. +The first real run, [Jenkins build 1](https://ci.yebilly.me/job/tikzrefinery-demo/1/), +checked out merged main `d37297b` and stopped at the frozen-file gate: the global +`*.dvi` ignore rule had excluded one original asset from the 434-file Git input, +although the local and exported rehearsals contained all 435 files. It also +exposed a missing JUnit reporting plugin. The correction retains the original +1,268-byte blob, adds an exact ignore exception and checks tracked provenance. +This failed run does not establish application compilation or artifact delivery. +The [job setup and verification runbook](jenkins/README.md) records prerequisites +and the remaining checks for the reviewed rerun. + ## Demonstration and ownership Use [the timed demonstration script](DEMO_SCRIPT.md) for the proposed speaker diff --git a/demo/ci/verify-snapshot.py b/demo/ci/verify-snapshot.py index 60e51d5..c549f1a 100644 --- a/demo/ci/verify-snapshot.py +++ b/demo/ci/verify-snapshot.py @@ -1,12 +1,36 @@ """Verify the exact frozen source input, independent of either Git checkout.""" +import argparse import hashlib import json from pathlib import Path +import subprocess + +parser = argparse.ArgumentParser(description=__doc__) +parser.add_argument('--require-tracked', action='store_true', + help='Also verify that the Git index contains every original blob.') +args = parser.parse_args() DEMO = Path(__file__).resolve().parents[1] SOURCE = DEMO / 'tikzrefinery' manifest = json.loads((DEMO / 'snapshot.json').read_text(encoding='utf-8')) expected = manifest['files'] +if args.require_tracked: + index = subprocess.check_output( + ['git', 'ls-files', '--stage', '-z', '--', 'demo/tikzrefinery'], cwd=DEMO.parent) + tracked = {} + for row in index.decode('utf-8').split('\0'): + if not row: + continue + metadata, path = row.split('\t', 1) + mode, blob, stage = metadata.split() + assert stage == '0', ('Unresolved snapshot index entry', path) + tracked[path.removeprefix('demo/tikzrefinery/')] = (mode, blob) + assert set(tracked) == set(expected), { + 'untracked_snapshot_files': sorted(set(expected) - set(tracked)), + 'unexpected_tracked_files': sorted(set(tracked) - set(expected))} + for name, identity in expected.items(): + assert tracked[name] == (identity['mode'], identity['git_blob']), ( + 'Git index differs from the frozen upstream blob', name) actual = {p.relative_to(SOURCE).as_posix() for p in SOURCE.rglob('*') if p.is_file()} assert actual == set(expected), {'missing': sorted(set(expected) - actual), 'extra': sorted(actual - set(expected))} @@ -17,4 +41,5 @@ for name, identity in expected.items(): assert git_blob == identity['git_blob'], name print(json.dumps({'result': 'passed', 'upstream_commit': manifest['upstream_commit'], 'application_baseline': manifest['application_baseline'], - 'verified_files': len(expected)}, indent=2)) + 'verified_files': len(expected), + 'git_index_verified': args.require_tracked}, indent=2)) diff --git a/demo/evidence/jenkins-baseline-20261126.json b/demo/evidence/jenkins-baseline-20261126.json new file mode 100644 index 0000000..3bc0bbe --- /dev/null +++ b/demo/evidence/jenkins-baseline-20261126.json @@ -0,0 +1,124 @@ +{ + "observations_completed_utc": "2026-11-26T05:23:22Z", + "job_url": "https://ci.yebilly.me/job/tikzrefinery-demo/", + "settings": { + "disabled": "false", + "definition": "org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition", + "url": "https://git.yebilly.me/ssw590-group1/vpn-dns-gateway.git", + "branch": "*/main", + "script_path": "demo/Jenkinsfile", + "lightweight": "true", + "trigger_count": 0 + }, + "existing_checkout_credential_reused": true, + "readiness": { + "observed_utc": "2026-11-26T05:23:22Z", + "toolchain_images": { + "ssw590-demo-toolchain:20261125": "sha256:b09f82b3ba76f4445ff596c8c9423ed97d1d4e0fb6de1a3396a43bea972a4471", + "ssw590-demo-runtime:20261125": "sha256:ae1ded13e2320283ddc1f18892e3aebd5ce005c949bb56c62964313f37475dd9" + }, + "memory_available_kib": 599628, + "swap_free_kib": 1490012, + "root_free_bytes": 5586022400, + "agent_running": true, + "manual_action_active": false + }, + "first_run": { + "build_url": "https://ci.yebilly.me/job/tikzrefinery-demo/1/", + "revision": "d37297b88993fd8c5428c2e732f32f4c9324b51b", + "result": "FAILURE", + "duration_ms": 26453, + "scm_checkout_verified": true, + "main_ancestry_passed": true, + "source_gate_error": "Missing original documents/assets/loop-example/loop-boxes.dvi; 434 of 435 originals tracked", + "post_action_error": "No such DSL method junit; required plugin was absent", + "native_report_architecture_package_stages": "skipped after source-gate failure", + "deployable_artifact_produced": false + }, + "reporting_plugin_preparation": { + "observed_utc": "2026-11-26T05:21:32Z", + "official_update_center": true, + "plugins": { + "junit": { + "version": "1458.1460.vd53b_087eeb_2c", + "required_core": "2.555.3" + }, + "plugin-util-api": { + "version": "7.1403.vd380b_c42e90c", + "required_core": "2.555.3" + }, + "font-awesome-api": { + "version": "7.3.1-1013.v0835a_879ec6d", + "required_core": "2.555.3" + }, + "bootstrap5-api": { + "version": "5.3.9-1156.va_4c7fef67c56", + "required_core": "2.555.3" + }, + "jquery3-api": { + "version": "3.7.1-687.v68d468e40b_30", + "required_core": "2.555.1" + }, + "echarts-api": { + "version": "6.1.0-1321.v86c4c5114494", + "required_core": "2.555.3" + }, + "antisamy-markup-formatter": { + "version": "173.v680e3a_b_69ff3", + "required_core": "2.479.1" + }, + "prism-api": { + "version": "1.30.0-741.v034eb_0b_0a_a_fa_", + "required_core": "2.555.1" + }, + "checks-api": { + "version": "441.v54e82638ca_71", + "required_core": "2.555.3" + } + }, + "installation_and_extensions_ui": "Success", + "junit_enabled_ui": true, + "junit_step_visible_in_snippet_generator": true, + "controller_started_at": "2026-11-23T06:31:09.102475939Z", + "restart_requested": false + }, + "local_repair_validation": { + "result": "passed", + "indexed_snapshot": { + "result": "passed", + "upstream_commit": "f4e3193d49a98efcf2f16c2aa22d6085ebe70f36", + "application_baseline": "0.1.4-alpha", + "verified_files": 435, + "git_index_verified": true + }, + "missing_index_entry_rejected": true, + "clean_index_export": { + "result": "passed", + "upstream_commit": "f4e3193d49a98efcf2f16c2aa22d6085ebe70f36", + "application_baseline": "0.1.4-alpha", + "verified_files": 435, + "git_index_verified": false + }, + "upstream_asset_sha256": "3e06555552c50c1f5abcac8a1d3fb2eedf7ff4a34c40d94859aa7d5082009a21", + "clean_export_bytes": 11050972, + "real_index_sha256_after_negative_test": "2633ae6ac5822ce1389418cf4faba97fbbfcc1eb7172c2852652f67060515000" + }, + "monitoring_view": { + "url": "https://metrics.yebilly.me/d/group1-sre/group-1-sre", + "chrome_charts_rendered": [ + "CPU utilization", + "available memory", + "root filesystem availability", + "HTTPS availability" + ], + "window": "Last 30 minutes; 30-second refresh; America/New_York", + "attribution_limit": "Shared host; build 1 did not execute application compilation" + }, + "remaining": [ + "Human commit/push/review/merge of the asset and verifier correction", + "Real Jenkins rerun from corrected reviewed main", + "JUnit, stage, archive, download and source/version verification", + "Separate Jenkins core 2.580.2 security maintenance", + "Issue-linked product increment only after the baseline passes" + ] +} diff --git a/demo/jenkins/README.md b/demo/jenkins/README.md new file mode 100644 index 0000000..b19e812 --- /dev/null +++ b/demo/jenkins/README.md @@ -0,0 +1,104 @@ +# TikZRefinery Jenkins job + +Use the separate [tikzrefinery-demo job](https://ci.yebilly.me/job/tikzrefinery-demo/). +It was created after verification of baseline PR #31's merge `d37297b`. +Existing pricing, recovery and multibranch jobs retain their configurations. + +| Setting | Value | +| --- | --- | +| Item type | Pipeline | +| Definition | Pipeline script from SCM; Git | +| Repository | `https://git.yebilly.me/ssw590-group1/vpn-dns-gateway.git` | +| Checkout credential | Existing `gitea-jenkins-bot`; no new credential | +| Branch | `*/main` | +| Script path | `demo/Jenkinsfile` | +| Lightweight checkout | Enabled | +| Triggers and parameters | None; trigger manually after review/merge | +| Agent | Existing `delivery-trusted` label, one executor | +| Concurrent builds | Disabled | +| Pipeline timeout and retention | 45 minutes; ten builds | + +The pipeline definition supplies the label, timeout, retention, source gates, +stage sequence and report/artifact publishers. It binds no pricing deployment +or registry credentials and performs no pricing promotion. Keep reviewed `main` +as its SCM selection; do not switch it to a PR branch or use Replay to bypass +the source gate. + +## Controller and worker prerequisites + +The controller must provide the JUnit Pipeline step, in addition to the existing +Git, Declarative Pipeline and artifact archiving capabilities. Its official +[JUnit plugin](https://plugins.jenkins.io/junit/) consumes the CTest XML report; +it does not execute or replace the C++ tests. Use the compatible release offered +by this controller's official update center, with its required dependencies. +Record the actual installed version after verifying that installation completed. +Do not install a release requiring a newer Jenkins core by forcing compatibility. + +On November 26, the official update center installed JUnit +`1458.1460.vd53b_087eeb_2c` and its eight required dependency plugins; installation +and loading extensions each reported success, and the installed JUnit entry was +enabled. The Pipeline Snippet Generator also lists the `junit` step, confirming +that it is available to pipelines. No restart was requested. This is the compatible version offered to the +existing Jenkins 2.580.1 controller, rather than a forced newer-core release. + +The controller separately advertises a core update to 2.580.2 for the +[October 28 security advisory](https://www.jenkins.io/security/advisory/2026-10-28/). +That maintenance is still pending; installing JUnit does not apply a core update. + +The existing worker needs Git, Python 3, Docker, its workspace volume and the two +image identities in `demo/toolchain.json`. `demo/ci/run-cloud.sh` verifies those +identities and maps its container workspace to the volume's actual host path. +Do not run `prepare-images.sh` merely to check readiness; rebuilding can change +the verified identities. + +Before starting, confirm the agent is connected and idle, no manual Actions or +other heavy delivery build is running, and the existing host has space for the +new checkout, compiler outputs, image archive and Jenkins archive copy. Observe +available RAM and swap alongside the configured stage limits. The November 26 +preflight observed 5.3 GiB available disk and about 687 MiB available RAM with +swap after the Actions build completed; these are historical observations, not +a permanent capacity guarantee. No new instance or plan is required. + +The existing [Group 1 SRE dashboard](https://metrics.yebilly.me/d/group1-sre/group-1-sre?from=now-30m&to=now&refresh=30s&timezone=America%2FNew_York) +was checked in Chrome: CPU, available-memory, root-filesystem and HTTPS charts +rendered. Retain the 30-minute window and 30-second refresh for rehearsal, then +adjust the window to include the real build. These charts describe the shared +host; build 1 never reached application compilation, so its graph window must +not be presented as successful native-build load evidence. + +## First run and correction + +[Build 1](https://ci.yebilly.me/job/tikzrefinery-demo/1/) used reviewed main +`d37297b88993fd8c5428c2e732f32f4c9324b51b` and the real cloud agent. Checkout and +main ancestry verification passed. The snapshot gate correctly rejected the +missing `documents/assets/loop-example/loop-boxes.dvi`: the local file existed, +but `*.dvi` excluded it from Git. Its original upstream SHA-256 is +`3e06555552c50c1f5abcac8a1d3fb2eedf7ff4a34c40d94859aa7d5082009a21`. +Compilation and later stages were skipped. Post-processing then reported that +the `junit` step was unavailable. Preserve this failed build as evidence. + +The prepared correction adds the exact upstream blob and a narrow ignore +exception, verifies both all 435 working files and their indexed blob identities, +and archives diagnostics before publishing test results. The original source +manifest and product code stay unchanged. Commit/push/review the correction +before the next baseline run from `main`. + +## Verification after the reviewed correction + +1. Record the triggering identity, current build URL, main revision and agent. +2. Confirm the first stage verifies the main ancestry and all 435 indexed/raw + upstream blobs. Observe the native, report, architecture and package stages. +3. Check the JUnit interface shows the eight expected passing suites. Keep + failures visible and inspect diagnostics rather than marking them successful. +4. Download this build's image archive, architecture ZIP, report, provenance and + `SHA256SUMS` through Jenkins. Run `demo/ci/verify-artifacts.py` against the + downloaded artifact folder, and compare its source/build identity with the UI. +5. Open a source-generated diagram and report. Show live shared-host monitoring + and retain the actual per-stage load CSVs and elapsed times. +6. Record the result, including cache reuse and shared-host limitations. A prior + Windows/SSH rehearsal is not a substitute for this Jenkins verification. + +Only after the baseline passes should the separate issue-linked product +increment be prepared. Retain artifacts and required grading evidence; remove +only reproducible scratch from the current task. Never prune shared images, +volumes, runner identities or older evidence during preparation. diff --git a/demo/tikzrefinery/documents/assets/loop-example/loop-boxes.dvi b/demo/tikzrefinery/documents/assets/loop-example/loop-boxes.dvi new file mode 100644 index 0000000..51a3115 Binary files /dev/null and b/demo/tikzrefinery/documents/assets/loop-example/loop-boxes.dvi differ diff --git a/manual/latex/devopsAIPromptLog.tex b/manual/latex/devopsAIPromptLog.tex index e4138da..0ccc35f 100644 --- a/manual/latex/devopsAIPromptLog.tex +++ b/manual/latex/devopsAIPromptLog.tex @@ -1302,3 +1302,68 @@ affected pages are visually reviewed. Frozen upstream bytes are checked again; the real artifact-only Jenkins baseline remains pending the reviewed merge. The merge is left ready for Vincent to commit and push. Codex does not commit, push, merge the remote PR, change approvals or run a pipeline in this task. + +\section{Jenkins Baseline Readiness and First Run} +Date: November 26, 2026 Eastern; Tool: OpenAI Codex; Human: Vincent Sun. +Vincent asked Codex to prepare what could proceed while Billy reviewed the +baseline resolution, then reported the merge. Codex read the project controls, +verified merged main \texttt{d37297b} for PR~31 and checked the existing paid +Droplet. The two toolchain image IDs matched the recorded identities. The +Actions manual build initially occupied the host; Codex waited until it ended. +The subsequent preflight observed 5.3\,GiB free disk and about 687\,MiB available +RAM with swap. It checked the existing delivery agent's required tools and +unprivileged account; no image preparation or additional cloud plan was needed. + +Codex created the following SCM Pipeline job in Chrome: +\begin{quote}\small +\path{tikzrefinery-demo} +\end{quote} +Its settings select reviewed main, script path +\path{demo/Jenkinsfile}, existing checkout credential, manual trigger and no +concurrent builds. The source definition retains its 45-minute timeout, +ten-build retention and existing trusted agent. No pricing or recovery job, +permission, credential, account or public port was changed. After the merge +and host-idle checks, Codex started the real baseline run, build~1. + +Jenkins obtained the pipeline, scheduled the real cloud agent and checked out +\texttt{d37297b}; main ancestry passed. The snapshot gate then correctly failed: +the global \texttt{*.dvi} ignore rule had excluded one original upstream asset +from Git. Codex's earlier local and exported rehearsal verification had checked +all 435 files on disk without checking that every file was tracked. The real +checkout contained 434. Compilation and all later stages were skipped. The +post action exposed a second missing prerequisite: no JUnit Pipeline step was +installed. Build~1 ended FAILURE in 26.453 seconds and remains preserved; it +is not presented as a successful application build or artifact delivery. + +Codex installed only JUnit and the dependencies selected by the official +Jenkins update center. The offered compatible JUnit version was +\texttt{1458.1460.vd53b\_087eeb\_2c}, requiring core 2.555.3; it runs on the +existing 2.580.1 controller. All nine installation entries and extension +loading reported success, and the installed JUnit entry was enabled. The +controller retained its November 23 start time. The public plugin page's +newest release required a newer core, so that release was not forced. The +controller also advertised the separate core security update to 2.580.2; +Codex verified the official October 28 advisory and records it as a separate +maintenance item, without changing core or weakening any protection here. + +On a new local verification branch from merged main, Codex prepared a narrow +ignore exception and staged the exact 1,268-byte upstream DVI blob. Its Git +object and SHA-256 match the original manifest; the senior checkout, manifest +and product source remain unchanged. The verifier now optionally checks every +indexed upstream blob and the Jenkins gate requires that check. Diagnostics +are archived before JUnit publication so a reporting failure cannot skip the +archive step. A negative test using an isolated alternate index rejected the +missing asset; the real index and a clean staged export verified all 435 files. + +The job runbook records actual configuration, plugin preparation and the +remaining SCM/stage/JUnit/download checks. Selected evidence is retained at: +\begin{quote}\small +\path{demo/evidence/jenkins-baseline-20261126.json} +\end{quote} +Detailed observations and validation remain in the ignored build folder. +Codex records these changes +in Hosts and Document History, rebuilds the complete manual with TinyTeX and +visually reviews affected pages. It does not commit, push, publish an issue, +approve or merge a PR, replay unreviewed pipeline code, or prepare the reserved +issue-linked product change. The corrected baseline must pass after human +review and merge before that next source increment begins. diff --git a/manual/latex/devopsDocumentHistory.tex b/manual/latex/devopsDocumentHistory.tex index 5efaf73..8406871 100644 --- a/manual/latex/devopsDocumentHistory.tex +++ b/manual/latex/devopsDocumentHistory.tex @@ -12,6 +12,7 @@ link each entry to the changed chapter, table, figure, or controlled artifact. \multicolumn{4}{l}{\small\itshape Document Update History (continued)}\\ \toprule \textbf{Date / Version} & \textbf{Author Initials} & \textbf{Change} & \textbf{Changed At}\\ \midrule \endhead \bottomrule \endlastfoot +November 26, 2026 / 6.4 baseline verification & VS, CDX & Verified the baseline merge, prepared the dedicated Jenkins job and ran build 1 from reviewed main. Recorded its missing tracked upstream asset and missing JUnit step; installed compatible JUnit reporting dependencies without a restart. Prepared the exact-blob repair, tracked provenance gate and job runbook. Local positive/negative and clean-export checks pass; a successful Jenkins baseline still awaits the reviewed repair. & \hyperref[Chapter:HostsPasswords]{Hosts}, \hyperref[Chapter:AIPromptLog]{AI log}\\ November 25, 2026 / 6.4 baseline integration & VS, CDX & Resolved the baseline PR conflicts against merged security PR~30, preserving both original AI and history records and the later access/rehearsal work. Verified the frozen snapshot and rebuilt the complete manual. Vincent retains commit/push and remote merge authority; the actual artifact-only Jenkins run remains pending. & \hyperref[Chapter:AIPromptLog]{AI log}\\ November 25, 2026 / 6.4 demo rehearsal & VS, CDX & Restored authorized home web access to Jenkins and Grafana with one /32 addition to the existing allowlist. Validated configuration, recreated only Caddy and verified authentication, denied-source behavior and healthy existing sites. Prepared a timed final-demo script, two-tool SWOT, configuration explanations and rubric checklist; actual baseline Jenkins verification and the subsequent issue-linked source increment remain pending review/merge. & \hyperref[Chapter:HostsPasswords]{Hosts}, \hyperref[Chapter:AIPromptLog]{AI log}\\ November 25, 2026 / 7.0 demo preparation & VS, CDX & Imported Vincent's frozen TikZRefinery 0.1.4-alpha checkpoint with byte-level provenance. Verified Windows and isolated cloud builds, eight suites on each platform, portable Windows module loading, both report editions, source-extracted diagrams and a versioned Linux image. Prepared an artifact-only Jenkins pipeline; actual Jenkins checkout/archive verification and the separate issue-linked provider rename remain pending. Existing assignments and live services are retained. & \hyperref[Chapter:AIPromptLog]{AI log}\\ diff --git a/manual/latex/devopsHostsPasswords.tex b/manual/latex/devopsHostsPasswords.tex index 504cc3b..785b17b 100644 --- a/manual/latex/devopsHostsPasswords.tex +++ b/manual/latex/devopsHostsPasswords.tex @@ -46,6 +46,15 @@ HTTPS login pages were reachable from the laptop; anonymous protected requests still required authentication, and an unlisted source received 403. Service accounts, application permissions and credential hints are unchanged. +On November 26, 2026, after Vincent merged the baseline PR, Codex created the +separate \texttt{tikzrefinery-demo} Jenkins job using reviewed main and the +existing checkout credential and trusted agent. Its first run stopped at the +snapshot gate; no application artifact was produced. Codex then installed the +compatible JUnit reporting plugin and its eight required library plugins from +the official update center. Installation and extension loading succeeded; +the controller retained its November 23 start time. No new account, credential, +public port or pricing deployment was introduced. + \section{Hosts} \small \begin{tabularx}{\linewidth}{@{}L{3.3cm}Y@{}}