From f63d379048305b995e17fa44e84995cec36610aa Mon Sep 17 00:00:00 2001 From: Joseph Doherty Date: Sun, 24 May 2026 07:17:41 -0400 Subject: [PATCH] docs: cross-reference docker-env2 from root README, CLAUDE.md, and infra README --- CLAUDE.md | 1 + README.md | 9 +++++++++ infra/README.md | 10 ++++++++++ 3 files changed, 20 insertions(+) diff --git a/CLAUDE.md b/CLAUDE.md index 0bf0f92..89403b0 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -9,6 +9,7 @@ When a change is requested, the default assumption is: update the design doc *an - `src/` — C#/.NET implementation, one project per component (e.g. `ScadaLink.AuditLog`, `ScadaLink.NotificationOutbox`, `ScadaLink.SiteCallAudit`, `ScadaLink.CentralUI`, `ScadaLink.Host`, …). Solution file: `ScadaLink.slnx`. - `tests/` — Test projects (unit + integration). - `docker/` — 8-node cluster topology (2 central + 3 sites), `deploy.sh`, per-node `appsettings.*.json`. See [`docker/README.md`](docker/README.md) for setup, ports, and management commands. Rebuild + redeploy with `bash docker/deploy.sh`. +- `docker-env2/` — Minimal second cluster topology (2 central + 1 site × 2 nodes), runs concurrently with `docker/` on host ports 91XX. Built specifically for testing the Transport (#24) feature with two real environments. See [`docker-env2/README.md`](docker-env2/README.md). Rebuild + redeploy with `bash docker-env2/deploy.sh`. - `infra/` — Docker Compose for local test services (LDAP, MS SQL, OPC UA, SMTP, REST API, Traefik). - `README.md` — Master index with component table and architecture diagrams. - `docs/requirements/HighLevelReqs.md` — Complete high-level requirements covering all functional areas. diff --git a/README.md b/README.md index fbabf30..7e87fb9 100644 --- a/README.md +++ b/README.md @@ -25,6 +25,15 @@ This document serves as the master index for the SCADA system design. The system - Central cluster: 2-node active/standby behind a load balancer. - Site clusters: 2-node active/standby, headless (no UI). +## Local Test Environments + +Two Docker-based cluster topologies are available for local development and testing: + +- **Primary** ([`docker/`](docker/)) — Full topology (2 central + 3 sites × 2 nodes + Traefik). Default development target. +- **Env2** ([`docker-env2/`](docker-env2/)) — Minimal sibling stack (2 central + 1 site × 2 nodes + Traefik), runs concurrently with primary on host ports 91XX. Purpose: exercise the Transport (#24) bundle export/import feature against a real second environment. + +Both stacks share the infrastructure services in [`infra/`](infra/) (MS SQL, LDAP, SMTP, OPC UA, REST API). + ## Document Map ### Requirements diff --git a/infra/README.md b/infra/README.md index 4788783..65d559b 100644 --- a/infra/README.md +++ b/infra/README.md @@ -37,6 +37,16 @@ docker exec -i scadalink-mssql /opt/mssql-tools18/bin/sqlcmd \ -i /docker-entrypoint-initdb.d/machinedata_seed.sql ``` +For the second environment (`docker-env2/`), also apply the env2 database setup: + +```bash +docker exec -i scadalink-mssql /opt/mssql-tools18/bin/sqlcmd \ + -S localhost -U sa -P 'ScadaLink_Dev1#' -C \ + -i /docker-entrypoint-initdb.d/setup-env2.sql +``` + +This creates `ScadaLinkConfig2` and `ScadaLinkMachineData2` databases on the same MSSQL instance. The script is also invoked automatically by `docker-env2/deploy.sh` via `docker-env2/init-db.sh`, so manual application here is only needed if you want the databases ready before first env2 deploy. + ## Stopping & Teardown **Stop containers** (data persists in SQL volume):