Skip to content

Commit f01d768

Browse files
committed
docs: add project roadmap and detailed Q&A clarifications
- Add comprehensive roadmap with 7 main sections covering app scaffolding, providers, services, Docker image, console commands, HTTPS support, and backup/recovery - Add detailed roadmap-questions.md with 68 questions covering scope, architecture, risks, and implementation details - Include answered clarifications about target users, configuration approach, deployment strategy, and technical decisions - Update project-words.txt with new terms used in documentation
1 parent 8fea6eb commit f01d768

File tree

3 files changed

+363
-0
lines changed

3 files changed

+363
-0
lines changed

docs/roadmap-questions.md

Lines changed: 271 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,271 @@
1+
# Roadmap Questions and Clarifications
2+
3+
This document contains questions about the [Torrust Tracker Deployer Roadmap](./roadmap.md) to help clarify scope, priorities, and implementation det**Q9.1:** Scalability considerations:
4+
5+
- What's the maximum expected environment size? **Very small.**
6+
- How do we handle resource limits and quotas? **Irrelevant for now.**
7+
- Performance implications of the incremental deployment approach? **It's not a big deal because we are not going to have big environments. The deployer is not designed to handle big environments with many instances. It's designed to handle small environments with one instance.**
8+
9+
## Scope and Requirements Questions
10+
11+
### 1. User Experience and Interface Design
12+
13+
**Q1.1:** What is the target user persona for this tool? Are we targeting:
14+
15+
- DevOps engineers familiar with infrastructure tools?
16+
- Developers who want simple deployment without infrastructure knowledge?
17+
- System administrators managing production deployments?
18+
19+
**Answer:** Mainly developers who want simple deployment without infrastructure knowledge. However, system administrators managing production deployments could also benefit from it, especially if they are comfortable with the way the deployer installs and configures services.
20+
21+
**Q1.2:** For the console commands (create, destroy, deploy, status, test), what level of interactivity is expected?
22+
23+
- Should these be fully automated with config files?
24+
- Do we need interactive prompts for missing configuration?
25+
- Should there be confirmation steps for destructive operations?
26+
27+
**Answer:** In the first version, we want these to be fully automated with config files. Commands should stop when there are missing configuration values and report a clear error. The only exception is the `destroy` command, which should ask for confirmation before proceeding.
28+
29+
**Q1.3:** What's the expected learning curve? Should the tool be:
30+
31+
- Self-documenting with extensive help and examples?
32+
- Assume familiarity with Docker, Ansible, and infrastructure concepts?
33+
34+
**Answer:** It should be self-documenting with extensive help and examples. However, for experienced users, it should allow access to low-level details if they want them.
35+
36+
### 2. Configuration and Environment Management
37+
38+
**Q2.1:** How will users provide configuration values for the `create` command?
39+
40+
- Configuration files (YAML, TOML, JSON)?
41+
- Command-line arguments?
42+
- Interactive prompts?
43+
- Environment variables?
44+
45+
**Answer:** The initial plan is to use configuration files (TOML) and environment variables because we have nested configuration structures (like arrays of trackers in the tracker TOML configuration). This approach is also aligned with other tools like the Torrust Tracker itself.
46+
47+
**Q2.2:** What's the scope of environment customization?
48+
49+
- Pre-defined templates with limited customization?
50+
- Full flexibility to customize all infrastructure aspects?
51+
- Preset configurations for different use cases (dev, staging, production)?
52+
53+
**Answer:** Users will only provide configuration values for predefined templates. Basically, the user has to provide the values that make an environment unique (like domain name, instance size, etc.) and the deployer will handle the rest using the templates.
54+
55+
**Q2.3:** Should environments support:
56+
57+
- Multi-region deployments? **No.**
58+
- Different instance sizes/types? **Yes, when we implement the Hetzner provider.**
59+
- Custom networking configurations? **Only firewall rules for now.**
60+
61+
## Execution Order and Dependencies
62+
63+
### 3. Implementation Sequence
64+
65+
**Q3.1:** Why is point 1 (main app scaffolding) prioritized over infrastructure providers?
66+
67+
- Is LXD sufficient for early development and testing?
68+
- Should Hetzner provider development start earlier to validate the abstraction?
69+
70+
**Answer:** We expect Hetzner to be easy to implement - it will only need new OpenTofu templates. The main complexity will be that the user's input will have two different parts: one for the common configuration and another for the provider-specific configuration. But this can be handled when we implement the Hetzner provider.
71+
72+
On the other hand, we have already implemented the Hetzner provider in previous proof of concepts, so we know it will be straightforward to implement.
73+
74+
**Q3.2:** For point 3 (application commands), should ConfigureCommand be fully completed before starting ReleaseCommand/RunCommand?
75+
76+
- Are there dependencies between firewall configuration and service deployment?
77+
- Can these be developed in parallel?
78+
79+
**Answer:** ConfigureCommand should be finished before starting ReleaseCommand/RunCommand. There are no dependencies between them. The firewall configuration is a basic configuration to close all ports except SSH. Later, when we add more services, we will need to update the firewall configuration to open the required ports for each service.
80+
81+
**Q3.3:** The Docker image (point 4) seems like it could enable easier testing of points 1-3. Should it be prioritized earlier?
82+
83+
**Answer:** We already use virtual machines and Docker for testing. Point 4 would be the full public official Docker image for the deployer.
84+
85+
### 4. Service Deployment Strategy
86+
87+
**Q4.1:** For the incremental service approach in 3.2, what's the deployment validation strategy?
88+
89+
- How do we ensure each service addition doesn't break existing services?
90+
- Should there be automated health checks between each service addition?
91+
92+
**Answer:** Each Ansible playbook should have its own validations for preconditions and postconditions. Besides that, we can incrementally add more functionality to the TestCommand depending on the environment state and the services that are deployed.
93+
94+
**Q4.2:** What's the rollback strategy if a service addition fails?
95+
96+
- Should each slice be independently deployable and removable?
97+
- How do we handle service dependencies (e.g., Tracker depends on MySQL)?
98+
99+
**Answer:** Each slice is not going to be added at runtime. The slice is only a concept to incrementally add more services to the deployer. After implementing the first slice, users will be able to deploy a hello-world Docker container instead of the real tracker. After the second iteration, they will be able to deploy a stack with MySQL. After the third iteration, they will be able to deploy the tracker connected to MySQL, and so on. At this point, the tracker will be operational but without the extra monitoring services like Prometheus and Grafana.
100+
101+
Note that after each step we only deploy a fully working Docker Compose stack. We don't have to handle rollbacks or partial deployments.
102+
103+
On the other hand, we are not planning to handle rollbacks for the full deployment (the deploy command). If something fails, the user will have to fix the issue and run the deploy command again. The deploy command should be idempotent and able to resume from a failed state. If it's not possible, the user will have to destroy the environment and create it again.
104+
105+
## Critical Missing Aspects
106+
107+
### 5. Security and Production Readiness
108+
109+
**Q5.1:** Security considerations seem minimal in the roadmap. What about:
110+
111+
- SSL/TLS certificate management (Let's Encrypt integration)?
112+
- Secrets management (API keys, database passwords)?
113+
- Network security beyond basic firewall configuration?
114+
- User authentication and access control?
115+
116+
**Answer:** This will be expanded in future iterations. The current plan is to use the Figment crate to load user inputs and save them securely. For secrets, the user can decide if they are provided in the configuration file or as environment variables (same approach as the Torrust Tracker).
117+
118+
**Action:** Add a point to the roadmap to add HTTPS support for the HTTP tracker, tracker API, and Grafana after having the full application running on HTTP.
119+
120+
**Q5.2:** Backup and disaster recovery:
121+
122+
- Database backups for MySQL?
123+
- Configuration backups?
124+
- Recovery procedures documentation?
125+
126+
**Answer:** This was included in previous proof of concepts, so we know how to implement it.
127+
128+
**Action:** Add a point to the roadmap for backup and disaster recovery in future iterations.
129+
130+
**Q5.3:** Monitoring and observability:
131+
132+
- Log aggregation and management?
133+
- Alerting integration beyond Prometheus/Grafana?
134+
- Performance monitoring and tuning?
135+
136+
### 6. Testing and Quality Assurance
137+
138+
**Q6.1:** What's the testing strategy for the incremental deployments?
139+
140+
- Integration tests for each service slice?
141+
- End-to-end testing of the complete stack?
142+
- Performance testing under load?
143+
144+
**Answer:** Only E2E tests for provisioning (already implemented) and E2E tests for the rest of the deployment process (simulate provisioned VM with Docker). This is also already implemented. We just need to expand the tests incrementally as we add more services.
145+
146+
**Q6.2:** How do we ensure consistency across different infrastructure providers?
147+
148+
- Cross-provider testing strategy?
149+
- Provider-specific feature parity validation?
150+
151+
Manual testing for now. Automated tests for non-local providers can be expensive.
152+
153+
### 7. Documentation and User Support
154+
155+
**Q7.1:** What documentation is planned beyond the technical docs?
156+
157+
- User guides for different deployment scenarios?
158+
- Troubleshooting guides for common issues?
159+
- Migration guides for existing setups?
160+
161+
Only basic user guides and troubleshooting guides for now. We should write them as we implement the features.
162+
163+
**Q7.2:** Error handling and user guidance:
164+
165+
- How detailed should error messages be? **As detailed as possible depending on the verbosity level.**
166+
- Should there be automated diagnostic tools? **Not many, there will be commands to check if the third-party tools are installed and working correctly.**
167+
- Recovery suggestions for common failure scenarios? **Yes, definitely.**
168+
169+
## Risk Assessment
170+
171+
### 8. Technical Risks
172+
173+
**Q8.1:** Provider abstraction complexity:
174+
175+
- How do we handle provider-specific features that don't map well to abstractions?
176+
- What's the fallback if a provider's API changes significantly?
177+
178+
**Answer:** We won't have abstractions per provider. Each provider will have its own configuration structure and the user will have to provide the configuration values for the selected provider. The common configuration values will be shared between all providers.
179+
180+
There is no fallback if a provider's API changes significantly. We will have to update the deployer to handle the new API. This is a risk that we have to accept when using third-party services.
181+
182+
**Q8.2:** Service orchestration complexity:
183+
184+
- How do we handle service startup order and dependencies? **We have to handle that in the best way possible. For example, we have a step to wait for cloud-init to finish before starting to configure the services. We can also add retries with exponential backoff when connecting to services that could not be ready yet (like MySQL).**
185+
- What happens when services fail to start or become unhealthy? **We only show and log the error and stop the deployment. The user will have to fix the issue and run the deploy command again.**
186+
187+
**Q8.3:** State management:
188+
189+
- How do we handle partial deployments or interrupted processes? **The environment state is already tracked and persisted, so we can resume from the last known good state.**
190+
- What's the strategy for state reconciliation after failures? **Failed states are not recoverable automatically. If the state is corrupted, the user will have to destroy the environment and create it again.**
191+
192+
### 9. Operational Risks
193+
194+
**Q9.1:** Scalability considerations:
195+
196+
- What's the maximum expected environment size? Very small.
197+
- How do we handle resource limits and quotas? Irrelevant for now.
198+
- Performance implications of the incremental deployment approach? It's not a big deal because we are not going to have big environments. The deployer is not designed to handle big environments with many instances. It's designed to handle small environments with one instance.
199+
200+
**Q9.2:** Maintenance burden:
201+
202+
- How do we handle updates to underlying services (MySQL, Tracker, etc.)? **We don't. The maintenance is out-of-scope for now. That's why we use Docker containers for the services, so the user can update them independently if needed.**
203+
- Dependency management for the tool itself? **Very simple for now. We will use Cargo to manage the dependencies. There are some scripts to install the required third-party tools (OpenTofu, Ansible, etc.).**
204+
- Long-term support and backward compatibility? **Not planned for now. It will depend on user feedback and the adoption of the tool.**
205+
206+
### 10. Project Management Risks
207+
208+
**Q10.1:** Resource allocation:
209+
210+
- What's the expected team size and expertise? **1 developer with experience in Rust.**
211+
- Are there external dependencies on other teams or projects? **On the Tracker project for new features, bug fixes, changes in configuration, but not critical.**
212+
213+
**Q10.2:** Timeline and scope creep:
214+
215+
- What's the minimum viable product (MVP) scope? **A basic implementation of the deployer with support for a single provider (Hetzner). Certificate management may be added later.**
216+
- Which features are must-have vs. nice-to-have? **Must-have: basic deployment functionality, support for Hetzner provider. Nice-to-have: support for additional providers, certificate management.**
217+
- How do we handle feature requests during development? **Include them in future iterations if they are not critical for the MVP.**
218+
219+
## Architecture and Design Questions
220+
221+
### 11. System Architecture
222+
223+
**Q11.1:** Command vs. Service boundary:
224+
225+
- How is the distinction between "console commands" and "internal app layer commands" maintained?
226+
- Should there be a clear service layer that both console and internal commands use?
227+
228+
**Answer:** There is a clear separation. We are following DDD layering principles. The console commands are in the presentation layer and the internal app layer commands are in the application layer. The application layer uses the domain layer to implement the business logic.
229+
230+
We might need to rename the application command to command handler or something similar to avoid confusion, and use the "command" term for the DTOs that represent the user input for each command.
231+
232+
**Q11.2:** State persistence:
233+
234+
- How is environment state tracked and persisted? **In a JSON file in the data directory for each environment.**
235+
- What happens to state when the tool is updated? **They should be migrated if there are breaking changes. But there are no real users yet. Not even a Beta version has been released.**
236+
- Should state be portable between different installations of the tool? **Not planned for now.**
237+
238+
**Q11.3:** Concurrency and parallel execution:
239+
240+
- Can multiple environments be managed simultaneously? **Yes, the tool is designed to handle multiple environments concurrently, but it's not a likely use case. It might happen for testing purposes.**
241+
- How do we handle concurrent operations on the same environment? **For now, there are simple locking mechanisms to prevent concurrent operations while saving the same environment. We could expand this in the future if needed. However, the main purpose of the tool is to handle one environment at a time.**
242+
243+
---
244+
245+
## Next Steps
246+
247+
**Completed:** All questions have been answered and clarified.
248+
249+
**Actions taken based on the responses:**
250+
251+
1.**Updated the roadmap** with clearer scope and requirements
252+
2.**Added missing critical aspects:**
253+
- Section 6: HTTPS support for HTTP tracker, tracker API, and Grafana
254+
- Section 7: Backup and disaster recovery capabilities
255+
3.**Clarified execution order** - confirmed current prioritization is appropriate
256+
4.**Documented risk mitigation strategies** through the detailed Q&A responses
257+
258+
**Key insights from the Q&A:**
259+
260+
- **Target users:** Primarily developers wanting simple deployment without infrastructure knowledge
261+
- **Configuration approach:** TOML files + environment variables (aligned with Torrust Tracker)
262+
- **Deployment strategy:** Incremental service slicing rather than deployment stage slicing
263+
- **MVP scope:** Basic deployer with Hetzner provider support, HTTPS may come later
264+
- **Architecture:** Clear DDD layering with separation between console and application commands
265+
- **Testing:** Focus on E2E tests, expanding incrementally with new services
266+
267+
**Remaining tasks:**
268+
269+
- Implement the roadmap features as prioritized
270+
- Create feature documentation in `docs/features/` before starting each major feature
271+
- Update this document if new questions arise during implementation

0 commit comments

Comments
 (0)