Skip to content

Document the codebase: JSDoc for the non-obvious modules #58

Description

@Alimedhat000

Summary

Several modules are hard to read without CONTEXT.md + the ADRs: the deployment pipeline, build-pack strategies, storage/symlink activation, the Docker runner, and Caddy config generation. Add inline documentation so a fresh agent can ramp up from the code.

Scope

  • JSDoc on public functions/types in:
    • worker/src/deployments/ — pipeline, strategies, storage (symlink activation), rollback, events.
    • worker/src/infrastructure/ — docker, caddy, retry, log-buffer.
    • api/src/routes/ and api/src/services/.
    • shared/src/utils/ (encryption).
  • Follow the existing JSDoc style already used in docker-runner.ts and retry.ts (terse @param/@returns, explain the why — e.g., the symlink swap, the port-conflict retry).
  • Align terminology with CONTEXT.md (Deployment, Build Job, Build Pack, activation) so docs read consistently.
  • No behavioral changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationneeds-triageMaintainer needs to evaluate the issue

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions