Compare commits

..
10 changed files with 365 additions and 4 deletions
+47
View File
@@ -0,0 +1,47 @@
name: Runner compatibility preflight
on:
push:
branches: [manual-runner-preflight]
jobs:
preflight:
runs-on: manual-latex
timeout-minutes: 10
permissions:
contents: read
steps:
- uses: https://github.com/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ github.sha }}
persist-credentials: false
- name: Verify revision, tools, and job boundary
env:
EXPECTED_SHA: ${{ github.sha }}
run: |
test "$(git rev-parse HEAD)" = "$EXPECTED_SHA"
test ! -e /var/run/docker.sock
test ! -e /data/.runner
mkdir -p preflight
python3 - <<'PY' > preflight/result.txt
import os, socket, urllib.request
print('Trigger commit:', os.environ['EXPECTED_SHA'])
print('HTTPS:', urllib.request.urlopen('https://myfileagent.tech/api/v1/version').read().decode())
for host, port in [('172.20.0.2', 3000), ('172.20.0.1', 3000)]:
s = socket.socket(); s.settimeout(2)
result = s.connect_ex((host, port)); s.close()
print('Private backend connection blocked:', result != 0)
assert result != 0
print('Docker socket and runner state absent from job')
PY
latexmk --version >> preflight/result.txt
pdflatex --version >> preflight/result.txt
pygmentize -V >> preflight/result.txt
node --version >> preflight/result.txt
python3 -c 'import pypdf; print(pypdf.__version__)' >> preflight/result.txt
cat preflight/result.txt
- name: Test artifact compatibility (not a manual PDF)
uses: https://github.com/actions/upload-artifact@c6a366c94c3e0affe28c06c8df20a878f24da3cf
with:
name: runner-preflight-${{ github.run_number }}
path: preflight/result.txt
if-no-files-found: error
retention-days: 14
+7
View File
@@ -0,0 +1,7 @@
{
acme_ca https://acme-v02.api.letsencrypt.org/directory
}
{$GITEA_HOSTNAME} {
reverse_proxy gitea:3000
}
+32 -4
View File
@@ -1,15 +1,36 @@
name: filepilot-gitea name: myfileagent-gitea
services: services:
caddy:
image: caddy:2.11.4-alpine
container_name: myfileagent-caddy
restart: unless-stopped
profiles:
- https
environment:
GITEA_HOSTNAME: ${GITEA_HOSTNAME:-localhost}
ports:
- "80:80"
- "443:443"
volumes:
- ./Caddyfile:/etc/caddy/Caddyfile:ro
- caddy-data:/data
- caddy-config:/config
networks:
- edge
- gitea-private
depends_on:
- gitea
gitea: gitea:
image: docker.gitea.com/gitea:1.27.3-rootless image: docker.gitea.com/gitea:1.27.3-rootless
container_name: filepilot-gitea container_name: myfileagent-gitea
restart: unless-stopped restart: unless-stopped
environment: environment:
GITEA__database__DB_TYPE: sqlite3 GITEA__database__DB_TYPE: sqlite3
GITEA__database__PATH: /var/lib/gitea/data/gitea.db GITEA__database__PATH: /var/lib/gitea/data/gitea.db
GITEA__server__DOMAIN: localhost GITEA__server__DOMAIN: "${GITEA_DOMAIN:-localhost}"
GITEA__server__ROOT_URL: http://localhost:3000/ GITEA__server__ROOT_URL: "${GITEA_ROOT_URL:-http://localhost:3000/}"
GITEA__server__HTTP_PORT: 3000 GITEA__server__HTTP_PORT: 3000
GITEA__server__DISABLE_SSH: "true" GITEA__server__DISABLE_SSH: "true"
GITEA__service__DISABLE_REGISTRATION: "true" GITEA__service__DISABLE_REGISTRATION: "true"
@@ -18,8 +39,15 @@ services:
volumes: volumes:
- gitea-data:/var/lib/gitea - gitea-data:/var/lib/gitea
- gitea-config:/etc/gitea - gitea-config:/etc/gitea
networks:
- gitea-private
volumes: volumes:
caddy-data:
caddy-config:
gitea-data: gitea-data:
gitea-config: gitea-config:
networks:
edge:
gitea-private:
+8
View File
@@ -0,0 +1,8 @@
FROM debian:bookworm-slim@sha256:7c7b2c966bc9ee8cedfeef67e0e279108992c77681fa595db4a9d65c06ccc587
# Immutable Debian snapshot fixes the TeX Live 2022 and supporting package set.
RUN rm /etc/apt/sources.list.d/debian.sources \
&& printf '%s\n' 'deb [check-valid-until=no] http://snapshot.debian.org/archive/debian/20261001T000000Z bookworm main' > /etc/apt/sources.list \
&& apt-get -o Acquire::Check-Valid-Until=false update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends ca-certificates git nodejs python3 python3-pygments python3-pypdf latexmk texlive-latex-extra texlive-fonts-recommended lmodern texlive-science poppler-utils \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /workspace
+121
View File
@@ -0,0 +1,121 @@
# Assignment 5 manual build infrastructure
Status on October 6, 2026: infrastructure preparation; the authoritative manual
has not been transferred. No manual PDF build or failure/repair exercise is
claimed. Assignment metadata must remain 1.7.1, October 6, 2026.
## Deployment
Existing host: /home/codex/myfileagent-gitea. Gitea 1.27.3 and Caddy 2.11.4
were left running. Public HTTPS remains https://myfileagent.tech, with the
Gitea backend bound to 127.0.0.1:3000 and its private Docker bridge. The existing
5050/8080 grading apps and SSH configuration were not changed.
Runner 0.6.1 is pinned by registry digest in runner-compose.yaml. The live
configuration is at /home/codex/myfileagent-gitea/runner. Registration is scoped to
myfileagent/myfileagent-pipeline; runner ID 1, name assignment5-manual,
label manual-latex, capacity one. Live runner state is outside Git in a
mode-700 directory; .runner is mode 600. No registration credential is in
Compose, source, or this record. The temporary implementation credential has
write:repository scope and is stored outside Git; revoke it when work ends.
The runner controls the host Docker socket and therefore has powerful host
access. Only trusted team workflows may run. Jobs have no socket, registration
state or permitted host-volume mounts. The runner exposes no ports, cache or
metrics listener. Jobs use the separate manual-build-jobs bridge, a 256 MiB
memory ceiling, no swap, 0.65 CPU and a PID limit of 256. The runner itself is
limited to 192 MiB (Go soft memory target 128 MiB) and 0.25 CPU. This does not protect the host against a malicious
trusted workflow or Docker administrator. Workflow triggers must remain push
only on main/manual-build-validation; do not enable untrusted PR jobs.
The repository is public, has no direct collaborators, and grants its Owners
team owner rights. No branch protections existed at preflight. Team review of
workflow changes remains a procedural control, not an enforced approval gate.
## Toolchain and evidence
Dockerfile pins Debian by digest and packages by the October 1, 2026 Debian
snapshot. It supplies TeX Live 2022, latexmk, minted/Pygments, Latin Modern,
recommended fonts, BibTeX, index/glossary tools, Node and pypdf. Full source
compatibility remains unverified until the real manual is available.
runner-preflight.yml is an isolated infrastructure test on branch
manual-runner-preflight. It is not one of the required manual source builds.
It tests exact-commit checkout, HTTPS, backend isolation, dependency presence,
and the pinned upload-artifact v3.2.2 protocol. Its text artifact has 14-day
retention; the eventual PDF workflow must also record its actual retention.
Checkout is pinned to v4.2.2 commit 11bd71901bbe5b1630ceea73d27597364c9af683.
Upload is pinned to v3.2.2 commit c6a366c94c3e0affe28c06c8df20a878f24da3cf.
## Source transfer and remaining work
Transfer the actual C:\Users\gowri\SSW590\assignment5\documentation directory,
including main.tex, all chapters, cornell.cls, bibliography/style files,
ci/build_manual.py, hw4_images and other referenced assets, plus the instruction
PDF dosManual-V1.18.pdf. Preserve the archive as an input and inspect it before
extracting. Exclude credentials and stale build/cache outputs from commits.
Use existing authenticated SSH/SFTP/SCP to stage the source archive under
/home/codex/myfileagent-gitea/incoming; do not open a public upload port.
Then verify dependencies, add the push-triggered manual workflow, generate
uncommitted visible version/commit/run metadata, and require a nonempty PDF.
Perform two successful source-change builds, the controlled error and repair
on manual-build-validation, update all eight chapter sections and history,
prompt log, Hosts/Passwords (explicit changed/unchanged), glossary and index.
Download and visually inspect the final successful Actions PDF artifact.
## Ownership, cost, cleanup and recovery
The MyFileAgent team owns the runner and storage. Preflight measured one CPU,
961 MiB RAM, about 292 MiB available memory, no swap, and 18 GiB free disk.
No paid resize or additional machine was purchased. Existing account billing
and transfer charges were not inspected; do not claim the work is free.
Stop only the added service with docker compose -f runner/compose.yaml stop
from the deployment directory. This preserves Gitea and historical data.
Remove runner ID 1 through repository Settings / Actions / Runners if retiring
it, then remove only its identified state and temporary credentials. Preserve
required artifacts before their retention expires. Do not prune all Docker
images, networks, volumes, or containers on this shared host.
For queued jobs check scope, online state, label and branch. For build failures
inspect the first LaTeX error and pinned dependencies. For uploads inspect the
PDF path and action compatibility. Check memory/disk before retrying.
References: https://docs.gitea.com/1.26/usage/actions/act-runner/;
https://docs.gitea.com/1.27/usage/actions/comparison/;
https://docs.gitea.com/1.27/administration/config-cheat-sheet/.
Compiler image built successfully: local immutable image ID
sha256:579106aaffa81dc2436a72a5dbfc51d3590f1a97646321fd38c694aae6d7cba1
(1.32 GB). The runner selects this exact local image ID with force_pull false.
Rebuilds on a replacement host must record their image ID before enabling jobs.
## Verified compatibility result
On October 6, 2026 (America/New_York), push commit
2fcbcbf6390273b8d3be14bfb656ec02ce050a97 completed successfully in
https://myfileagent.tech/myfileagent/myfileagent-pipeline/actions/runs/2 .
The downloaded text artifact is
https://myfileagent.tech/myfileagent/myfileagent-pipeline/actions/runs/2/artifacts/runner-preflight-2 .
Its ZIP SHA-256 is recorded in evidence-2026-10-06.json; the extracted payload
is preserved in preflight-result-2.txt. The actual checks passed: triggering
revision, HTTPS, blocked direct private backend/gateway port 3000, absent
Docker socket/runner state, and compiler dependencies. This does not imply
all outbound destinations or other host ports are blocked.
The pinned upload-artifact v3.2.2 action works with this server. Its legacy
artifact is downloadable from the run URL but absent from the newer REST
artifact listing. Use the run's named download link for this protocol. Retention
is requested as 14 days; expiry enforcement has not yet been observed.
The pending manual workflow is in manual-pdf.yml.example, not activated.
The first preflight hit the runner's 96 MiB cap during action download. Its
orphaned container was stopped; the cap is now 192 MiB with GOMEMLIMIT=128MiB.
Run 2 then passed without another runner restart. This infrastructure repair
is NOT the required controlled LaTeX error and repair exercise.
No original manual chapter, history, glossary, Hosts or Passwords table was
modified on this host because its authoritative source is still missing.
Once transferred, incorporate these verified facts into the single complete
devopsAutomatedManualBuild.tex and preserve prior history.
+51
View File
@@ -0,0 +1,51 @@
{
"observed_at_utc": "2026-10-07T01:13:05.277196+00:00",
"assignment": "5",
"document_version": "1.7.1",
"document_date": "2026-10-06",
"gitea_version": "1.27.3",
"runner_version": "0.6.1",
"runner_id": 1,
"runner_scope": "myfileagent/myfileagent-pipeline",
"concurrency": 1,
"runner_memory_mib": 192,
"job_memory_mib": 256,
"runner_image": "gitea/act_runner@sha256:b5c35d6bdbb9bb25e531230bfc7cc663cb751406cbec90a2a891b85fea54de86",
"compiler_image_id": "sha256:579106aaffa81dc2436a72a5dbfc51d3590f1a97646321fd38c694aae6d7cba1",
"source_transfer": "pending; incoming directory empty",
"manual_builds_verified": 0,
"preflight_1": {
"commit": "194cce7c657ff1166c4cddb5dd6f47bfa9c97e93",
"run_url": "https://myfileagent.tech/myfileagent/myfileagent-pipeline/actions/runs/1",
"observed_result": "runner hit 96 MiB memory limit during action clone; orphan job container stopped"
},
"preflight_2": {
"commit": "2fcbcbf6390273b8d3be14bfb656ec02ce050a97",
"run_url": "https://myfileagent.tech/myfileagent/myfileagent-pipeline/actions/runs/2",
"observed_result": "success; downloaded artifact verified",
"artifact_name": "runner-preflight-2",
"artifact_url": "https://myfileagent.tech/myfileagent/myfileagent-pipeline/actions/runs/2/artifacts/runner-preflight-2",
"artifact_zip_sha256": "03e9f73aae55c2fa5151471732a253bf297398d9004edc6890f2dcf88d412273",
"retention_days_requested": 14,
"rest_artifact_listing": "empty for this legacy v3 artifact; direct run download verified",
"checks": [
"exact triggering commit",
"HTTPS certificate verification",
"private Gitea backend and gateway port 3000 unreachable from job",
"no Docker socket or runner state in job",
"latexmk 4.79",
"TeX Live 2022/Debian",
"Pygments 2.14.0",
"Node 18.20.4",
"pypdf 3.4.1"
]
},
"preserved_services": [
"Gitea",
"Caddy",
"hello-node on 5050",
"color-buttons-app on 8080"
],
"secret_boundary": "runner state and temporary repository write token outside Git, restricted storage; no credential values in evidence",
"hosts_passwords_manual_tables": "unchanged remotely; authoritative manual unavailable"
}
+36
View File
@@ -0,0 +1,36 @@
# Activate as .gitea/workflows/manual-pdf.yml only after the authoritative
# documentation sources have been transferred and clean compilation verified.
name: Assignment 5 manual PDF
on:
push:
branches: [main, manual-build-validation]
jobs:
manual:
runs-on: manual-latex
timeout-minutes: 30
permissions:
contents: read
steps:
- uses: https://github.com/actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ github.sha }}
persist-credentials: false
- name: Compile the complete manual with visible build identity
env:
GITEA_SHA: ${{ github.sha }}
GITEA_RUN_NUMBER: ${{ github.run_number }}
GITEA_RUN_ID: ${{ github.run_id }}
GITEA_RUN_ATTEMPT: ${{ github.run_attempt }}
run: |
python3 documentation/ci/build_manual.py
test -s documentation/build/main.pdf
test -s documentation/build/build-manifest.json
- name: Publish verified PDF and traceability manifest
uses: https://github.com/actions/upload-artifact@c6a366c94c3e0affe28c06c8df20a878f24da3cf
with:
name: assignment5-1.7.1-run-${{ github.run_number }}-${{ github.sha }}
path: |
documentation/build/main.pdf
documentation/build/build-manifest.json
if-no-files-found: error
retention-days: 14
+21
View File
@@ -0,0 +1,21 @@
Trigger commit: 2fcbcbf6390273b8d3be14bfb656ec02ce050a97
HTTPS: {"version":"1.27.3"}
Private backend connection blocked: True
Private backend connection blocked: True
Docker socket and runner state absent from job
Latexmk, John Collins, 7 Jan. 2023. Version 4.79
pdfTeX 3.141592653-2.6-1.40.24 (TeX Live 2022/Debian)
kpathsea version 6.3.4
Copyright 2022 Han The Thanh (pdfTeX) et al.
There is NO warranty. Redistribution of this software is
covered by the terms of both the pdfTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the pdfTeX source.
Primary author of pdfTeX: Han The Thanh (pdfTeX) et al.
Compiled with libpng 1.6.39; using libpng 1.6.39
Compiled with zlib 1.2.13; using zlib 1.2.13
Compiled with xpdf version 4.04
Pygments version 2.14.0, (c) 2006-2022 by Georg Brandl, Matthäus Chajdas and contributors.
v18.20.4
3.4.1
+20
View File
@@ -0,0 +1,20 @@
name: manual-build
services:
runner:
image: gitea/act_runner:0.6.1@sha256:b5c35d6bdbb9bb25e531230bfc7cc663cb751406cbec90a2a891b85fea54de86
container_name: myfileagent-manual-runner
restart: unless-stopped
entrypoint: [act_runner]
command: [daemon, --config, /config.yaml]
mem_limit: 192m
memswap_limit: 192m
environment:
GOMEMLIMIT: 128MiB
cpus: 0.25
volumes:
- ./state:/data
- ./config.yaml:/config.yaml:ro
- /var/run/docker.sock:/var/run/docker.sock
networks: [runner-egress]
networks:
runner-egress:
+22
View File
@@ -0,0 +1,22 @@
log:
level: info
runner:
file: /data/.runner
capacity: 1
timeout: 30m
shutdown_timeout: 30s
insecure: false
labels:
- manual-latex:docker://sha256:579106aaffa81dc2436a72a5dbfc51d3590f1a97646321fd38c694aae6d7cba1
cache:
enabled: false
container:
network: manual-build-jobs
privileged: false
options: --memory=256m --memory-swap=256m --cpus=0.65 --pids-limit=256
valid_volumes: []
docker_host: '-'
force_pull: false
force_rebuild: false
metrics:
enabled: false