Files
pikasTech-HWLAB/README.md
T
2026-05-22 07:17:33 +00:00

103 lines
3.1 KiB
Markdown

# HWLAB
HWLAB is the hardware lab runtime and control plane for MVP development.
This repository is intentionally small at L0. It defines the shared protocol
contract, schema skeletons, deploy manifest schema, and minimal validation
entry points that later service implementations must follow.
## MVP Freeze
- MVP scope is DEV only.
- DEV browser/frontend endpoint is fixed at `http://74.48.78.17:16666/`.
- DEV API/edge/live endpoint is fixed at `http://74.48.78.17:16667`.
- Legacy `:6666` and `:6667` are historical/deprecated only and are not MVP
acceptance targets.
- UniDesk may be used only as an external scheduling, CI, or CD base.
- HWLAB runtime services must not be replaced by UniDesk backend,
provider-gateway, or microservice proxy implementations.
## Frozen Service IDs
- `hwlab-cloud-api`
- `hwlab-cloud-web`
- `hwlab-agent-mgr`
- `hwlab-agent-worker`
- `hwlab-gateway`
- `hwlab-gateway-simu`
- `hwlab-box-simu`
- `hwlab-patch-panel`
- `hwlab-router`
- `hwlab-tunnel-client`
- `hwlab-edge-proxy`
- `hwlab-cli`
- `hwlab-agent-skills`
## Frozen Repository Layout
The MVP branches may add implementation files under these paths:
- `cmd/...`
- `internal/...`
- `web/hwlab-cloud-web`
- `tools/hwlab-cli`
- `skills`
- `protocol/schemas`
- `deploy/deploy.json`
- `deploy/k8s/base/dev/prod`
- `deploy/master-edge`
- `deploy/frp`
- `scripts/bootstrap-skills.sh`
- `scripts/worker-entrypoint.sh`
## Contract Index
- Protocol contract: [protocol/README.md](protocol/README.md)
- JSON-RPC envelope: [protocol/json-rpc.md](protocol/json-rpc.md)
- Error codes: [protocol/errors.md](protocol/errors.md)
- Audit fields: [protocol/audit.md](protocol/audit.md)
- Capability model: [protocol/capabilities.md](protocol/capabilities.md)
- Topology constraints: [protocol/topology.md](protocol/topology.md)
- MVP e2e contract: [protocol/mvp-e2e-contract.md](protocol/mvp-e2e-contract.md)
- JSON Schemas: [protocol/schemas](protocol/schemas)
- Deploy schema: [deploy/deploy.schema.json](deploy/deploy.schema.json)
- M3 rollout support runbook: [docs/reference/m3-loop-rollout-runbook.md](docs/reference/m3-loop-rollout-runbook.md)
## Validation
Run the lightweight validation suite:
```sh
npm run check
```
Run only the L2 gateway/box simulator runtime smoke:
```sh
npm run l2:smoke
```
## L6 Manual Acceptance Entry
The external MVP acceptance surface is DEV-only and report-driven:
```sh
npm run l6:smoke
npm run web:m3-readonly
npm run web:check
npm run cli:dry-run
node tools/hwlab-cli/bin/hwlab-cli.mjs test e2e --env dev --mvp
```
`npm run web:m3-readonly` is the Cloud Web #59 guardrail: it checks that the
browser entry remains on public `:16666`, API/edge diagnostics remain on public
`:16667`, the page only calls read-only diagnostics RPCs, and M3 stays blocked
unless the real `DO1 -> hwlab-patch-panel -> DI1` DEV-LIVE evidence exists.
The CLI command defaults to a JSON dry-run plan sourced from
`reports/dev-gate/dev-mvp-gate-report.json` and
`fixtures/mvp/m5-e2e/dry-run-plan.json`. A live DEV attempt requires
`--live --confirm-dev --confirmed-non-production`; with open gate blockers it
returns `BLOCKED` evidence rather than using fixtures or UniDesk runtime as a
substitute.