chore(local): add local Oracle dev/test harness - #545
Conversation
8f5052d to
e1eb5b9
Compare
|
Ran a hostile self-review and fixed the findings (pushed):
Verified: compose YAML parses, ports bind loopback-only, |
Add a docker-compose-based local harness (dev signal only, never compliance evidence): moto for the RDS control-plane request-shape smoke, and gvenzl/oracle-free + oracle-19c for the SQL hardening/assessment loop, driven by a Makefile (doctor/quickstart/unit/moto-smoke). assess->harden->assess runs inside the container via docker exec (no host Instant Client). README documents the overlay-sibling-clone requirement. Security/hygiene: - All published ports bind to 127.0.0.1 only (Oracle 1521/1522, moto 5000) so the dev DB with its known local-only password is never reachable from the LAN/VPN. - moto image pinned to 5.2.2 (was :latest) for reproducibility. - local/.gitignore ignores generated reports/ (dev-signal output, never commit) and force-tracks init/*.sql past the global *.sql ignore; the referenced init seed scripts are now included so oracle-up actually seeds the non-SYS user + weak state the README describes.
e1eb5b9 to
70be202
Compare
|
📋 Merge order: 2️⃣ of 4 (local dev/test harness — |
Rename terse variables in moto-smoke.sh for readability: EP -> MOTO_ENDPOINT, ID -> INSTANCE_ID, PG -> PARAM_GROUP, OG -> OPTION_GROUP. No behavioral change.
Add a note that make commands run from the repo root (with the in-local alternative), and render the layer-3 clone layout with tree connectors and a <workspace> root label.
The development-signal-only caveat is covered by the local/README.md banner and the harness Makefile; the per-script line was redundant.
Layer-1 unit tests pull in go-sqlite3 (a cgo package) and segfault under the default CGO_ENABLED=0; force CGO_ENABLED=1 in the harness Makefile so 'make unit' works out of the box. Add a doctor check for a C compiler (cc/gcc/clang) as a hard layer-1 prerequisite, upgrade the aws check to 'MISSING for layer 2', and give both macOS and Linux install hints. Broaden the prereqs header/table to cover macOS arm64 and Linux.
The 'brew install --cask cinc-auditor' guidance was outdated: we run cinc-auditor via Docker to avoid the cinc-workstation install (needs root). Update the doctor check and README prereqs/§3 to use a 'docker run cincproject/auditor' recipe, noting the overlay derives an image with Oracle Instant Client for its sqlplus-based oracledb_session controls.
The single-shot curl check raced 'make moto-up': the container's HTTP listener can lag a beat behind 'docker compose up -d' returning, so back-to-back moto-up && moto-smoke failed on the first miss. Poll :5000 once per second up to MOTO_TIMEOUT (default 10s) instead. Co-authored-by: OpenCode Agent <peter.burkholder@gsa.gov>
Proposed ADR (for discussion): Drop the local Oracle 19c Enterprise Edition image from the test harness
Context and Problem StatementThe Decision Drivers
Considered Options
Decision OutcomeChosen option: Option 3 — remove the EE dependency and keep Positive Consequences
Negative Consequences
Compliance Consequences
Links
|
No local SE2 image is possible on arm64 — Oracle's buildContainerImage.sh
supports only 19c EE and 26ai Free ('-s' errors out). An EE image is the
wrong edition (exposes EE-only TDE/FGA that the brokered SE2 lacks and the
design compensates for), risking a misleading local pass. Edition-accurate
STIG conformance is validated on a real brokered RDS SE2 instance regardless,
so the harness keeps only the freely-pullable gvenzl/oracle-free (23c) engine.
Remove docker-compose.oracle-19c.yml, the oracle19c-up target + COMPOSE_ORACLE19C
var + down/quickstart references, and retitle the README to state the 23c engine
vs 19c-on-RDS target. Rationale captured in the README §3 note (docs/oracle19c/
updates deferred to #537, where those files live).
Co-authored-by: OpenCode Agent <peter.burkholder@gsa.gov>
|
I don't think the above comment really needs to be documented beyond what's in the local/README.md file. |
Split out of #537 to keep that PR focused on the shipping broker code.
Adds a docker-compose-based local harness for developing/exercising the Oracle work locally. Dev signal only — never compliance evidence (live GovCloud RDS proof is separate).
motofor the RDS control-plane request-shape smoke.gvenzl/oracle-free+ an Oracle 19c compose for the SQL hardening/assessment loop.Makefile(doctor/quickstart/unit/moto-smoke);assess -> harden -> assessruns inside the container viadocker exec(no host Oracle Instant Client required).local/README.mddocuments the overlay-sibling-clone requirement.Touches only
local/; no application or CI-pipeline changes.Closes
Closes #529(WS10/11 — Oracle 19c: SQL hardening package + local test harness). The authoritative SQL lives in the overlay repo; this is the local dev loop for it.