Overview
Implement the CLI presentation layer for the configure command, exposing the existing ConfigureCommandHandler application layer logic to end users. This enables users to transition deployment environments from "Provisioned" state to "Configured" state via the CLI interface.
Specification
See detailed specification: docs/issues/180-implement-configure-cli-command.md
🏗️ Architecture Requirements
DDD Layer: Presentation
Module Path: src/presentation/controllers/configure/
Pattern: CLI Subcommand Controller
Module Structure Requirements
Architectural Constraints
Anti-Patterns to Avoid
- ❌ Implementing configuration logic in presentation layer
- ❌ Direct infrastructure calls (use application layer)
- ❌ Generic error messages without help guidance
Implementation Plan
Phase 1: CLI Command Definition (15 min)
Phase 2: Presentation Controller (1-2 hours)
Phase 3: Integration (30 min)
Phase 4: Testing (1-2 hours)
Phase 5: Manual E2E Testing (30 min)
Acceptance Criteria
Note for Contributors: These criteria define what the PR reviewer will check. Use this as your pre-review checklist before submitting the PR to minimize back-and-forth iterations.
Quality Checks:
Functional Requirements:
User Experience:
Code Quality:
Testing:
Architecture Compliance:
Related
Notes
Estimated Time: 4-6 hours
Reference Implementation: Follow the exact pattern from src/presentation/controllers/provision/
No New Business Logic: All configuration logic already exists in ConfigureCommandHandler - this task only exposes it via CLI.
Overview
Implement the CLI presentation layer for the
configurecommand, exposing the existingConfigureCommandHandlerapplication layer logic to end users. This enables users to transition deployment environments from "Provisioned" state to "Configured" state via the CLI interface.Specification
See detailed specification: docs/issues/180-implement-configure-cli-command.md
🏗️ Architecture Requirements
DDD Layer: Presentation
Module Path:
src/presentation/controllers/configure/Pattern: CLI Subcommand Controller
Module Structure Requirements
provisioncontroller:mod.rs,errors.rs,handler.rs,tests/Architectural Constraints
ConfigureCommandHandler)ExecutionContextpattern for dependency injection.help()with actionable guidanceAnti-Patterns to Avoid
Implementation Plan
Phase 1: CLI Command Definition (15 min)
Configurevariant toCommandsenum insrc/presentation/input/cli/commands.rs--helpPhase 2: Presentation Controller (1-2 hours)
src/presentation/controllers/configure/directorymod.rswith module documentation and exportserrors.rswithConfigureSubcommandErrorand.help()methodshandler.rswith progress reporting and state validationPhase 3: Integration (30 min)
src/presentation/dispatch/router.rsCommandErrorinsrc/presentation/errors.rssrc/presentation/controllers/mod.rsto export configure modulePhase 4: Testing (1-2 hours)
Phase 5: Manual E2E Testing (30 min)
Acceptance Criteria
Quality Checks:
./scripts/pre-commit.shFunctional Requirements:
torrust-tracker-deployer configure <name>command is availableUser Experience:
.help()method--helpoutputCode Quality:
Testing:
Architecture Compliance:
ExecutionContextpatternConfigureCommandHandlerRelated
Notes
Estimated Time: 4-6 hours
Reference Implementation: Follow the exact pattern from
src/presentation/controllers/provision/No New Business Logic: All configuration logic already exists in
ConfigureCommandHandler- this task only exposes it via CLI.