@@ -129,7 +129,9 @@ Command wrappers provide clean abstractions for integrating with external deploy
129
129
Provides integration with `Ansible ` for configuration management and software installation on remote systems .
130
130
131
131
- ✅ `src / ansible / mod . rs` - Ansible playbook integration and coordination
132
- - ✅ `src / ansible / template_renderer . rs` - Ansible - specific template rendering
132
+ - ✅ `src / ansible / template / mod . rs` - Ansible template functionality module
133
+ - ✅ `src / ansible / template / renderer / mod . rs` - Ansible template rendering coordination
134
+ - ✅ `src / ansible / template / renderer / inventory . rs` - Ansible inventory template rendering
133
135
134
136
* * Command Wrappers : **
135
137
@@ -286,7 +288,9 @@ Template wrappers provide specialized rendering logic for different tool configu
286
288
Specialized integration for `OpenTofu ` template processing , handling infrastructure - as - code template rendering with proper variable substitution .
287
289
288
290
- ✅ `src / tofu / mod . rs` - OpenTofu integration module
289
- - ✅ `src / tofu / template_renderer . rs` - OpenTofu template rendering
291
+ - ✅ `src / tofu / template / mod . rs` - OpenTofu template functionality module
292
+ - ✅ `src / tofu / template / renderer / mod . rs` - OpenTofu template rendering coordination
293
+ - ✅ `src / tofu / template / renderer / cloud_init . rs` - Cloud - init template rendering for OpenTofu
290
294
291
295
## � Architecture Flow
292
296
@@ -328,9 +332,47 @@ The typical deployment flow follows this pattern:
328
332
- * * Progress reporting** : User - friendly feedback during long- running operations
329
333
- * * Configuration system** : Support for different environments and settings
330
334
331
- ## 📊 Module Statistics
335
+ ## � Recent Architecture Improvements
332
336
333
- - * * Total Modules ** : 79 Rust files
337
+ ### Hierarchical Module Organization (September 2024)
338
+
339
+ Recent refactoring efforts have improved the module organization for both `Ansible ` and `OpenTofu ` integrations:
340
+
341
+ * * Before : **
342
+ ```
343
+ src/ ansible/ template_renderer. rs
344
+ src/ tofu/ template_renderer. rs
345
+ src/ tofu/ cloud_init_template_renderer. rs
346
+ ```
347
+
348
+ * * After : **
349
+ ```
350
+ src/ ansible/ template/
351
+ ├── mod . rs
352
+ └── renderer/
353
+ ├── mod . rs (AnsibleTemplateRenderer )
354
+ └── inventory. rs (InventoryTemplateRenderer )
355
+
356
+ src/ tofu/ template/
357
+ ├── mod . rs
358
+ └── renderer/
359
+ ├── mod . rs (TofuTemplateRenderer )
360
+ └── cloud_init. rs (CloudInitTemplateRenderer )
361
+ ```
362
+
363
+ * * Benefits of the New Structure : **
364
+
365
+ - * * Eliminated Redundant Naming ** : Removed `_template_renderer` suffixes from file names
366
+ - * * Logical Hierarchy ** : Clear `template/ renderer/ ` organization pattern
367
+ - * * Better Separation ** : Specialized renderers properly grouped by functionality
368
+ - * * Consistent Pattern ** : Same organizational approach across both modules
369
+ - * * Improved Maintainability ** : Easier to locate and modify specific template renderers
370
+
371
+ This refactoring maintains full backward compatibility while providing a cleaner, more maintainable codebase structure.
372
+
373
+ ## �📊 Module Statistics
374
+
375
+ - * * Total Modules ** : 85 Rust files
334
376
- * * Architecture Levels ** : 3 (Commands → Steps → Remote Actions )
335
377
- * * External Tool Integrations ** : 4 (`OpenTofu `, `Ansible `, `LXD `, `SSH `)
336
378
- * * Step Categories ** : 7 (Infrastructure , System , Software , Validation , Connectivity , Application , Rendering )
@@ -344,3 +386,4 @@ The typical deployment flow follows this pattern:
344
386
- * * Template - Driven Configuration ** : Flexible configuration management through templates
345
387
346
388
389
+ ````
0 commit comments