mcp-souschef 2.5.3__tar.gz → 2.8.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/PKG-INFO +56 -21
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/README.md +43 -20
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/pyproject.toml +10 -2
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/__init__.py +10 -2
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/assessment.py +14 -14
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ci/github_actions.py +5 -5
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ci/gitlab_ci.py +4 -4
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ci/jenkins_pipeline.py +4 -4
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/cli.py +12 -12
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/converters/__init__.py +2 -2
- mcp_souschef-2.8.0/souschef/converters/cookbook_specific.py +125 -0
- mcp_souschef-2.8.0/souschef/converters/cookbook_specific.py.backup +109 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/converters/playbook.py +853 -15
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/converters/resource.py +103 -1
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/constants.py +13 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/path_utils.py +12 -9
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/deployment.py +24 -24
- mcp_souschef-2.8.0/souschef/parsers/attributes.py +622 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/recipe.py +48 -10
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/server.py +35 -37
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ui/app.py +1413 -252
- mcp_souschef-2.8.0/souschef/ui/health_check.py +36 -0
- mcp_souschef-2.8.0/souschef/ui/pages/ai_settings.py +497 -0
- mcp_souschef-2.8.0/souschef/ui/pages/cookbook_analysis.py +1360 -0
- mcp_souschef-2.5.3/souschef/parsers/attributes.py +0 -257
- mcp_souschef-2.5.3/souschef/ui/pages/cookbook_analysis.py +0 -425
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/LICENSE +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ci/__init__.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/converters/habitat.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/__init__.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/errors.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/ruby_utils.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/core/validation.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/filesystem/__init__.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/filesystem/operations.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/__init__.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/habitat.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/inspec.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/metadata.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/resource.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/parsers/template.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/profiling.py +0 -0
- {mcp_souschef-2.5.3 → mcp_souschef-2.8.0}/souschef/ui/__init__.py +0 -0
|
@@ -1,31 +1,43 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mcp-souschef
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.8.0
|
|
4
4
|
Summary: AI-powered MCP server for Chef to Ansible conversion
|
|
5
5
|
License: MIT
|
|
6
6
|
License-File: LICENSE
|
|
7
|
+
Keywords: chef,ansible,migration,infrastructure,automation,mcp,ai,conversion
|
|
7
8
|
Author: SousChef Contributors
|
|
8
9
|
Requires-Python: >=3.14,<4.0
|
|
10
|
+
Classifier: Development Status :: 4 - Beta
|
|
11
|
+
Classifier: Intended Audience :: Developers
|
|
12
|
+
Classifier: Intended Audience :: System Administrators
|
|
9
13
|
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
10
15
|
Classifier: Programming Language :: Python :: 3
|
|
11
16
|
Classifier: Programming Language :: Python :: 3.14
|
|
17
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
18
|
+
Classifier: Topic :: System :: Systems Administration
|
|
19
|
+
Classifier: Topic :: Utilities
|
|
12
20
|
Provides-Extra: ui
|
|
13
21
|
Requires-Dist: anthropic (>=0.75.0)
|
|
14
22
|
Requires-Dist: click (>=8.1.0)
|
|
15
23
|
Requires-Dist: mcp (>=1.25.0)
|
|
24
|
+
Requires-Dist: openai (>=1.0.0)
|
|
16
25
|
Requires-Dist: pandas (>=2.0.0) ; extra == "ui"
|
|
17
26
|
Requires-Dist: plotly (>=5.0.0)
|
|
18
27
|
Requires-Dist: python-dotenv (>=1.2.1)
|
|
19
28
|
Requires-Dist: pyyaml (>=6.0.0)
|
|
20
29
|
Requires-Dist: streamlit (>=1.28.0)
|
|
21
30
|
Requires-Dist: zod (>=0.8.0)
|
|
31
|
+
Project-URL: Documentation, https://kpeacocke.github.io/souschef/
|
|
32
|
+
Project-URL: Homepage, https://github.com/kpeacocke/souschef
|
|
33
|
+
Project-URL: Repository, https://github.com/kpeacocke/souschef
|
|
22
34
|
Description-Content-Type: text/markdown
|
|
23
35
|
|
|
24
36
|
# Chef to Ansible migration - SousChef MCP
|
|
25
37
|
|
|
26
38
|
An AI-powered MCP (Model Context Protocol) server that provides comprehensive Chef-to-Ansible migration capabilities for enterprise infrastructure transformation.
|
|
27
39
|
|
|
28
|
-
[](https://github.com/kpeacocke/souschef/releases)
|
|
29
41
|
[](https://www.python.org/downloads/)
|
|
30
42
|
[](https://opensource.org/licenses/MIT)
|
|
31
43
|
[](htmlcov/index.html)
|
|
@@ -37,17 +49,17 @@ An AI-powered MCP (Model Context Protocol) server that provides comprehensive Ch
|
|
|
37
49
|
|
|
38
50
|
## Overview - Chef to Ansible features
|
|
39
51
|
|
|
40
|
-
SousChef is a complete enterprise-grade migration platform with **
|
|
52
|
+
SousChef is a complete enterprise-grade migration platform with **32 primary MCP tools** organised across **10 major capability areas** to facilitate Chef-to-Ansible AWX/AAP migrations. From cookbook analysis to deployment pattern conversion, including Chef Habitat to containerised deployments and CI/CD pipeline generation, SousChef provides everything needed for a successful infrastructure automation migration.
|
|
41
53
|
|
|
42
54
|
### About Tool Counts
|
|
43
55
|
|
|
44
|
-
**Why
|
|
56
|
+
**Why 32 tools in the documentation but more in the server?**
|
|
45
57
|
|
|
46
|
-
The MCP server provides **37 total tools** (35 public + 2 internal). This documentation focuses on the **
|
|
58
|
+
The MCP server provides **37 total tools** (35 public + 2 internal). This documentation focuses on the **32 primary user-facing tools** that cover the main migration capabilities. The remaining 3 tools are low-level filesystem operations and helper utilities used internally by the main tools.
|
|
47
59
|
|
|
48
60
|
As a user, you'll primarily interact with the 27 documented tools. Your AI assistant may use the additional tools automatically when needed, but you don't need to know about them for successful migrations.
|
|
49
61
|
|
|
50
|
-
>
|
|
62
|
+
> **For developers:** See `souschef/server.py` for the complete list of all 37 registered tools.
|
|
51
63
|
|
|
52
64
|
## Model Agnostic - Works with Any AI Model
|
|
53
65
|
|
|
@@ -95,7 +107,7 @@ Complete cookbook introspection and analysis tools:
|
|
|
95
107
|
- **list_directory** - Navigate and explore cookbook directory structures
|
|
96
108
|
- **read_file** - Read cookbook files with error handling
|
|
97
109
|
- **read_cookbook_metadata** - Parse metadata.rb files for dependencies and cookbook information
|
|
98
|
-
- **parse_recipe** -
|
|
110
|
+
- **parse_recipe** - Analyse Chef recipes and extract resources, actions, and properties
|
|
99
111
|
- **parse_attributes** - Parse attribute files with **advanced precedence resolution** (6 levels: default, force_default, normal, override, force_override, automatic)
|
|
100
112
|
- **list_cookbook_structure** - Display complete cookbook directory hierarchy
|
|
101
113
|
|
|
@@ -116,7 +128,7 @@ Convert Chef search patterns to dynamic Ansible inventory:
|
|
|
116
128
|
|
|
117
129
|
- **convert_chef_search_to_inventory** - Transform Chef search queries to Ansible inventory groups
|
|
118
130
|
- **generate_dynamic_inventory_script** - Create dynamic inventory scripts from Chef server queries
|
|
119
|
-
- **
|
|
131
|
+
- **analyse_chef_search_patterns** - Discover and analyse search usage in cookbooks
|
|
120
132
|
|
|
121
133
|
### 4. InSpec Integration & Validation
|
|
122
134
|
Complete InSpec-to-Ansible testing pipeline:
|
|
@@ -130,14 +142,14 @@ Chef data bags to Ansible vars/vault conversion:
|
|
|
130
142
|
|
|
131
143
|
- **convert_chef_databag_to_vars** - Transform data bags to Ansible variable files
|
|
132
144
|
- **generate_ansible_vault_from_databags** - Convert encrypted data bags to Ansible Vault
|
|
133
|
-
- **
|
|
145
|
+
- **analyse_chef_databag_usage** - Analyse data bag usage patterns in cookbooks
|
|
134
146
|
|
|
135
147
|
### 6. Environment & Configuration Management
|
|
136
148
|
Chef environments to Ansible inventory groups:
|
|
137
149
|
|
|
138
150
|
- **convert_chef_environment_to_inventory_group** - Transform Chef environments to inventory
|
|
139
151
|
- **generate_inventory_from_chef_environments** - Generate complete inventory from environments
|
|
140
|
-
- **
|
|
152
|
+
- **analyse_chef_environment_usage** - Analyse environment usage in cookbooks
|
|
141
153
|
|
|
142
154
|
### 7. AWX/Ansible Automation Platform Integration
|
|
143
155
|
Enterprise AWX/AAP configuration generation:
|
|
@@ -263,10 +275,10 @@ Output formats:
|
|
|
263
275
|
- **json**: Structured JSON for programmatic processing
|
|
264
276
|
- **summary**: Quick overview with counts only
|
|
265
277
|
|
|
266
|
-
- **
|
|
278
|
+
- **analyse_chef_application_patterns** - Identify application deployment patterns
|
|
267
279
|
- **assess_chef_migration_complexity** - Comprehensive migration complexity assessment
|
|
268
280
|
- **generate_migration_plan** - Create detailed migration execution plans
|
|
269
|
-
- **
|
|
281
|
+
- **analyse_cookbook_dependencies** - Analyse dependencies and migration order
|
|
270
282
|
- **generate_migration_report** - Generate executive and technical migration reports
|
|
271
283
|
|
|
272
284
|
## Migration Workflow
|
|
@@ -276,8 +288,8 @@ Output formats:
|
|
|
276
288
|
# Assess migration complexity
|
|
277
289
|
assess_chef_migration_complexity /path/to/cookbooks
|
|
278
290
|
|
|
279
|
-
#
|
|
280
|
-
|
|
291
|
+
# Analyse cookbook dependencies
|
|
292
|
+
analyse_cookbook_dependencies /path/to/cookbook
|
|
281
293
|
|
|
282
294
|
# Generate migration plan
|
|
283
295
|
generate_migration_plan '{\"cookbooks\": [\"/path/to/cookbook1\", \"/path/to/cookbook2\"]}'
|
|
@@ -369,6 +381,29 @@ souschef ui
|
|
|
369
381
|
souschef ui --port 8080
|
|
370
382
|
```
|
|
371
383
|
|
|
384
|
+
**Run in Docker:**
|
|
385
|
+
```bash
|
|
386
|
+
# Build the image
|
|
387
|
+
docker build -t souschef-ui .
|
|
388
|
+
|
|
389
|
+
# Run the container
|
|
390
|
+
docker run -p 8501:8501 souschef-ui
|
|
391
|
+
|
|
392
|
+
# Or use docker-compose
|
|
393
|
+
docker-compose up
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
**Docker Compose (recommended for development):**
|
|
397
|
+
```yaml
|
|
398
|
+
version: '3.8'
|
|
399
|
+
services:
|
|
400
|
+
souschef-ui:
|
|
401
|
+
build: .
|
|
402
|
+
ports:
|
|
403
|
+
- "8501:8501"
|
|
404
|
+
restart: unless-stopped
|
|
405
|
+
```
|
|
406
|
+
|
|
372
407
|
**Features:**
|
|
373
408
|
- Clean, professional design matching documentation standards
|
|
374
409
|
- Real-time cookbook analysis with progress indicators
|
|
@@ -592,7 +627,7 @@ Each MCP tool includes comprehensive documentation:
|
|
|
592
627
|
- **[Testing Strategy Guide](docs/testing-strategy.md)** - Validation and testing approaches
|
|
593
628
|
- **[Best Practices](docs/best-practices.md)** - Recommended patterns and approaches
|
|
594
629
|
|
|
595
|
-
##
|
|
630
|
+
## Contributing
|
|
596
631
|
|
|
597
632
|
We welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for:
|
|
598
633
|
- Development setup and workflow
|
|
@@ -600,13 +635,13 @@ We welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for:
|
|
|
600
635
|
- Pull request process
|
|
601
636
|
- Issue reporting guidelines
|
|
602
637
|
|
|
603
|
-
##
|
|
638
|
+
## License
|
|
604
639
|
|
|
605
640
|
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
|
606
641
|
|
|
607
642
|
## Roadmap
|
|
608
643
|
|
|
609
|
-
### Completed
|
|
644
|
+
### Completed
|
|
610
645
|
- Complete Chef cookbook parsing (recipes, attributes, metadata, templates)
|
|
611
646
|
- InSpec profile parsing and conversion to Testinfra/Ansible tests
|
|
612
647
|
- Chef resource to Ansible task conversion with module mapping
|
|
@@ -637,7 +672,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
637
672
|
- **Real-time progress tracking** for all analysis operations with Streamlit progress bars
|
|
638
673
|
- **Static graph visualization** with matplotlib for reports and documentation
|
|
639
674
|
|
|
640
|
-
### Planned
|
|
675
|
+
### Planned
|
|
641
676
|
- 📅 Enhanced graph layout algorithms for large dependency networks (force-directed, hierarchical)
|
|
642
677
|
- 📅 Export functionality for graphs (PNG, SVG, PDF formats)
|
|
643
678
|
- 📅 UI configuration options and themes
|
|
@@ -649,7 +684,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
649
684
|
- 📅 Migration templates and presets
|
|
650
685
|
- 📅 Terraform provider for infrastructure state management
|
|
651
686
|
|
|
652
|
-
##
|
|
687
|
+
## Support & Community
|
|
653
688
|
|
|
654
689
|
- **Issues**: [GitHub Issues](https://github.com/kpeacocke/souschef/issues)
|
|
655
690
|
- **Discussions**: [GitHub Discussions](https://github.com/kpeacocke/souschef/discussions)
|
|
@@ -657,7 +692,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
657
692
|
|
|
658
693
|
---
|
|
659
694
|
|
|
660
|
-
**SousChef** - *Transforming infrastructure automation, one recipe at a time.*
|
|
695
|
+
**SousChef** - *Transforming infrastructure automation, one recipe at a time.*
|
|
661
696
|
desc 'Ensure package nginx is properly configured'
|
|
662
697
|
impact 1.0
|
|
663
698
|
|
|
@@ -1374,5 +1409,5 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
1374
1409
|
|
|
1375
1410
|
---
|
|
1376
1411
|
|
|
1377
|
-
**SousChef** - *Ansible automation, one recipe at a time.*
|
|
1412
|
+
**SousChef** - *Ansible automation, one recipe at a time.*
|
|
1378
1413
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
An AI-powered MCP (Model Context Protocol) server that provides comprehensive Chef-to-Ansible migration capabilities for enterprise infrastructure transformation.
|
|
4
4
|
|
|
5
|
-
[](https://github.com/kpeacocke/souschef/releases)
|
|
6
6
|
[](https://www.python.org/downloads/)
|
|
7
7
|
[](https://opensource.org/licenses/MIT)
|
|
8
8
|
[](htmlcov/index.html)
|
|
@@ -14,17 +14,17 @@ An AI-powered MCP (Model Context Protocol) server that provides comprehensive Ch
|
|
|
14
14
|
|
|
15
15
|
## Overview - Chef to Ansible features
|
|
16
16
|
|
|
17
|
-
SousChef is a complete enterprise-grade migration platform with **
|
|
17
|
+
SousChef is a complete enterprise-grade migration platform with **32 primary MCP tools** organised across **10 major capability areas** to facilitate Chef-to-Ansible AWX/AAP migrations. From cookbook analysis to deployment pattern conversion, including Chef Habitat to containerised deployments and CI/CD pipeline generation, SousChef provides everything needed for a successful infrastructure automation migration.
|
|
18
18
|
|
|
19
19
|
### About Tool Counts
|
|
20
20
|
|
|
21
|
-
**Why
|
|
21
|
+
**Why 32 tools in the documentation but more in the server?**
|
|
22
22
|
|
|
23
|
-
The MCP server provides **37 total tools** (35 public + 2 internal). This documentation focuses on the **
|
|
23
|
+
The MCP server provides **37 total tools** (35 public + 2 internal). This documentation focuses on the **32 primary user-facing tools** that cover the main migration capabilities. The remaining 3 tools are low-level filesystem operations and helper utilities used internally by the main tools.
|
|
24
24
|
|
|
25
25
|
As a user, you'll primarily interact with the 27 documented tools. Your AI assistant may use the additional tools automatically when needed, but you don't need to know about them for successful migrations.
|
|
26
26
|
|
|
27
|
-
>
|
|
27
|
+
> **For developers:** See `souschef/server.py` for the complete list of all 37 registered tools.
|
|
28
28
|
|
|
29
29
|
## Model Agnostic - Works with Any AI Model
|
|
30
30
|
|
|
@@ -72,7 +72,7 @@ Complete cookbook introspection and analysis tools:
|
|
|
72
72
|
- **list_directory** - Navigate and explore cookbook directory structures
|
|
73
73
|
- **read_file** - Read cookbook files with error handling
|
|
74
74
|
- **read_cookbook_metadata** - Parse metadata.rb files for dependencies and cookbook information
|
|
75
|
-
- **parse_recipe** -
|
|
75
|
+
- **parse_recipe** - Analyse Chef recipes and extract resources, actions, and properties
|
|
76
76
|
- **parse_attributes** - Parse attribute files with **advanced precedence resolution** (6 levels: default, force_default, normal, override, force_override, automatic)
|
|
77
77
|
- **list_cookbook_structure** - Display complete cookbook directory hierarchy
|
|
78
78
|
|
|
@@ -93,7 +93,7 @@ Convert Chef search patterns to dynamic Ansible inventory:
|
|
|
93
93
|
|
|
94
94
|
- **convert_chef_search_to_inventory** - Transform Chef search queries to Ansible inventory groups
|
|
95
95
|
- **generate_dynamic_inventory_script** - Create dynamic inventory scripts from Chef server queries
|
|
96
|
-
- **
|
|
96
|
+
- **analyse_chef_search_patterns** - Discover and analyse search usage in cookbooks
|
|
97
97
|
|
|
98
98
|
### 4. InSpec Integration & Validation
|
|
99
99
|
Complete InSpec-to-Ansible testing pipeline:
|
|
@@ -107,14 +107,14 @@ Chef data bags to Ansible vars/vault conversion:
|
|
|
107
107
|
|
|
108
108
|
- **convert_chef_databag_to_vars** - Transform data bags to Ansible variable files
|
|
109
109
|
- **generate_ansible_vault_from_databags** - Convert encrypted data bags to Ansible Vault
|
|
110
|
-
- **
|
|
110
|
+
- **analyse_chef_databag_usage** - Analyse data bag usage patterns in cookbooks
|
|
111
111
|
|
|
112
112
|
### 6. Environment & Configuration Management
|
|
113
113
|
Chef environments to Ansible inventory groups:
|
|
114
114
|
|
|
115
115
|
- **convert_chef_environment_to_inventory_group** - Transform Chef environments to inventory
|
|
116
116
|
- **generate_inventory_from_chef_environments** - Generate complete inventory from environments
|
|
117
|
-
- **
|
|
117
|
+
- **analyse_chef_environment_usage** - Analyse environment usage in cookbooks
|
|
118
118
|
|
|
119
119
|
### 7. AWX/Ansible Automation Platform Integration
|
|
120
120
|
Enterprise AWX/AAP configuration generation:
|
|
@@ -240,10 +240,10 @@ Output formats:
|
|
|
240
240
|
- **json**: Structured JSON for programmatic processing
|
|
241
241
|
- **summary**: Quick overview with counts only
|
|
242
242
|
|
|
243
|
-
- **
|
|
243
|
+
- **analyse_chef_application_patterns** - Identify application deployment patterns
|
|
244
244
|
- **assess_chef_migration_complexity** - Comprehensive migration complexity assessment
|
|
245
245
|
- **generate_migration_plan** - Create detailed migration execution plans
|
|
246
|
-
- **
|
|
246
|
+
- **analyse_cookbook_dependencies** - Analyse dependencies and migration order
|
|
247
247
|
- **generate_migration_report** - Generate executive and technical migration reports
|
|
248
248
|
|
|
249
249
|
## Migration Workflow
|
|
@@ -253,8 +253,8 @@ Output formats:
|
|
|
253
253
|
# Assess migration complexity
|
|
254
254
|
assess_chef_migration_complexity /path/to/cookbooks
|
|
255
255
|
|
|
256
|
-
#
|
|
257
|
-
|
|
256
|
+
# Analyse cookbook dependencies
|
|
257
|
+
analyse_cookbook_dependencies /path/to/cookbook
|
|
258
258
|
|
|
259
259
|
# Generate migration plan
|
|
260
260
|
generate_migration_plan '{\"cookbooks\": [\"/path/to/cookbook1\", \"/path/to/cookbook2\"]}'
|
|
@@ -346,6 +346,29 @@ souschef ui
|
|
|
346
346
|
souschef ui --port 8080
|
|
347
347
|
```
|
|
348
348
|
|
|
349
|
+
**Run in Docker:**
|
|
350
|
+
```bash
|
|
351
|
+
# Build the image
|
|
352
|
+
docker build -t souschef-ui .
|
|
353
|
+
|
|
354
|
+
# Run the container
|
|
355
|
+
docker run -p 8501:8501 souschef-ui
|
|
356
|
+
|
|
357
|
+
# Or use docker-compose
|
|
358
|
+
docker-compose up
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
**Docker Compose (recommended for development):**
|
|
362
|
+
```yaml
|
|
363
|
+
version: '3.8'
|
|
364
|
+
services:
|
|
365
|
+
souschef-ui:
|
|
366
|
+
build: .
|
|
367
|
+
ports:
|
|
368
|
+
- "8501:8501"
|
|
369
|
+
restart: unless-stopped
|
|
370
|
+
```
|
|
371
|
+
|
|
349
372
|
**Features:**
|
|
350
373
|
- Clean, professional design matching documentation standards
|
|
351
374
|
- Real-time cookbook analysis with progress indicators
|
|
@@ -569,7 +592,7 @@ Each MCP tool includes comprehensive documentation:
|
|
|
569
592
|
- **[Testing Strategy Guide](docs/testing-strategy.md)** - Validation and testing approaches
|
|
570
593
|
- **[Best Practices](docs/best-practices.md)** - Recommended patterns and approaches
|
|
571
594
|
|
|
572
|
-
##
|
|
595
|
+
## Contributing
|
|
573
596
|
|
|
574
597
|
We welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for:
|
|
575
598
|
- Development setup and workflow
|
|
@@ -577,13 +600,13 @@ We welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for:
|
|
|
577
600
|
- Pull request process
|
|
578
601
|
- Issue reporting guidelines
|
|
579
602
|
|
|
580
|
-
##
|
|
603
|
+
## License
|
|
581
604
|
|
|
582
605
|
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
|
583
606
|
|
|
584
607
|
## Roadmap
|
|
585
608
|
|
|
586
|
-
### Completed
|
|
609
|
+
### Completed
|
|
587
610
|
- Complete Chef cookbook parsing (recipes, attributes, metadata, templates)
|
|
588
611
|
- InSpec profile parsing and conversion to Testinfra/Ansible tests
|
|
589
612
|
- Chef resource to Ansible task conversion with module mapping
|
|
@@ -614,7 +637,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
614
637
|
- **Real-time progress tracking** for all analysis operations with Streamlit progress bars
|
|
615
638
|
- **Static graph visualization** with matplotlib for reports and documentation
|
|
616
639
|
|
|
617
|
-
### Planned
|
|
640
|
+
### Planned
|
|
618
641
|
- 📅 Enhanced graph layout algorithms for large dependency networks (force-directed, hierarchical)
|
|
619
642
|
- 📅 Export functionality for graphs (PNG, SVG, PDF formats)
|
|
620
643
|
- 📅 UI configuration options and themes
|
|
@@ -626,7 +649,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
626
649
|
- 📅 Migration templates and presets
|
|
627
650
|
- 📅 Terraform provider for infrastructure state management
|
|
628
651
|
|
|
629
|
-
##
|
|
652
|
+
## Support & Community
|
|
630
653
|
|
|
631
654
|
- **Issues**: [GitHub Issues](https://github.com/kpeacocke/souschef/issues)
|
|
632
655
|
- **Discussions**: [GitHub Discussions](https://github.com/kpeacocke/souschef/discussions)
|
|
@@ -634,7 +657,7 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
634
657
|
|
|
635
658
|
---
|
|
636
659
|
|
|
637
|
-
**SousChef** - *Transforming infrastructure automation, one recipe at a time.*
|
|
660
|
+
**SousChef** - *Transforming infrastructure automation, one recipe at a time.*
|
|
638
661
|
desc 'Ensure package nginx is properly configured'
|
|
639
662
|
impact 1.0
|
|
640
663
|
|
|
@@ -1351,4 +1374,4 @@ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file
|
|
|
1351
1374
|
|
|
1352
1375
|
---
|
|
1353
1376
|
|
|
1354
|
-
**SousChef** - *Ansible automation, one recipe at a time.*
|
|
1377
|
+
**SousChef** - *Ansible automation, one recipe at a time.*
|
|
@@ -1,15 +1,23 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "mcp-souschef"
|
|
3
|
-
version = "2.
|
|
3
|
+
version = "2.8.0"
|
|
4
4
|
description = "AI-powered MCP server for Chef to Ansible conversion"
|
|
5
5
|
readme = "README.md"
|
|
6
|
+
homepage = "https://github.com/kpeacocke/souschef"
|
|
7
|
+
repository = "https://github.com/kpeacocke/souschef"
|
|
8
|
+
documentation = "https://kpeacocke.github.io/souschef/"
|
|
9
|
+
keywords = ["chef", "ansible", "migration", "infrastructure", "automation", "mcp", "ai", "conversion"]
|
|
6
10
|
authors = ["SousChef Contributors"]
|
|
7
11
|
license = "MIT"
|
|
8
12
|
packages = [{include = "souschef"}]
|
|
13
|
+
classifiers = ["Development Status :: 4 - Beta", "Intended Audience :: Developers", "Intended Audience :: System Administrators", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.14", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: System :: Systems Administration", "Topic :: Utilities"]
|
|
14
|
+
|
|
15
|
+
[tool.poetry.urls]
|
|
9
16
|
|
|
10
17
|
[tool.poetry.dependencies]
|
|
11
18
|
python = ">=3.14,<4.0"
|
|
12
19
|
anthropic = ">=0.75.0"
|
|
20
|
+
openai = ">=1.0.0"
|
|
13
21
|
click = ">=8.1.0"
|
|
14
22
|
mcp = ">=1.25.0"
|
|
15
23
|
python-dotenv = ">=1.2.1"
|
|
@@ -82,7 +90,7 @@ testpaths = [
|
|
|
82
90
|
[tool.coverage.run]
|
|
83
91
|
source = ["souschef"]
|
|
84
92
|
relative_files = true
|
|
85
|
-
omit = ["tests/*", "examples/*"]
|
|
93
|
+
omit = ["tests/*", "examples/*", "souschef/ui/*"]
|
|
86
94
|
|
|
87
95
|
[tool.coverage.report]
|
|
88
96
|
exclude_lines = [
|
|
@@ -1,17 +1,25 @@
|
|
|
1
1
|
"""SousChef: AI-powered Chef to Ansible converter."""
|
|
2
2
|
|
|
3
3
|
from souschef.assessment import (
|
|
4
|
-
|
|
4
|
+
analyse_cookbook_dependencies,
|
|
5
5
|
assess_chef_migration_complexity,
|
|
6
6
|
generate_migration_plan,
|
|
7
7
|
generate_migration_report,
|
|
8
8
|
validate_conversion,
|
|
9
9
|
)
|
|
10
|
+
from souschef.deployment import (
|
|
11
|
+
analyse_chef_application_patterns,
|
|
12
|
+
)
|
|
13
|
+
from souschef.server import (
|
|
14
|
+
analyse_chef_search_patterns,
|
|
15
|
+
)
|
|
10
16
|
|
|
11
17
|
__all__ = [
|
|
12
|
-
"
|
|
18
|
+
"analyse_cookbook_dependencies",
|
|
13
19
|
"assess_chef_migration_complexity",
|
|
14
20
|
"generate_migration_plan",
|
|
15
21
|
"generate_migration_report",
|
|
16
22
|
"validate_conversion",
|
|
23
|
+
"analyse_chef_application_patterns",
|
|
24
|
+
"analyse_chef_search_patterns",
|
|
17
25
|
]
|
|
@@ -63,7 +63,7 @@ def _process_cookbook_assessment(
|
|
|
63
63
|
valid_paths = _parse_cookbook_paths(cookbook_paths)
|
|
64
64
|
|
|
65
65
|
# Analyze all cookbooks (handles empty list gracefully)
|
|
66
|
-
cookbook_assessments, overall_metrics =
|
|
66
|
+
cookbook_assessments, overall_metrics = _analyse_cookbook_metrics(valid_paths)
|
|
67
67
|
|
|
68
68
|
# Generate recommendations and reports
|
|
69
69
|
recommendations = _generate_migration_recommendations_from_assessment(
|
|
@@ -111,7 +111,7 @@ def parse_chef_migration_assessment(
|
|
|
111
111
|
valid_paths = _parse_cookbook_paths(cookbook_paths)
|
|
112
112
|
|
|
113
113
|
# Analyze all cookbooks (handles empty list gracefully)
|
|
114
|
-
cookbook_assessments, overall_metrics =
|
|
114
|
+
cookbook_assessments, overall_metrics = _analyse_cookbook_metrics(valid_paths)
|
|
115
115
|
|
|
116
116
|
# Generate recommendations and reports
|
|
117
117
|
recommendations = _generate_migration_recommendations_from_assessment(
|
|
@@ -294,11 +294,11 @@ def generate_migration_plan(
|
|
|
294
294
|
return format_error_with_context(e, "generating migration plan", cookbook_paths)
|
|
295
295
|
|
|
296
296
|
|
|
297
|
-
def
|
|
297
|
+
def analyse_cookbook_dependencies(
|
|
298
298
|
cookbook_path: str, dependency_depth: str = "direct"
|
|
299
299
|
) -> str:
|
|
300
300
|
"""
|
|
301
|
-
|
|
301
|
+
Analyse cookbook dependencies and identify migration order requirements.
|
|
302
302
|
|
|
303
303
|
Args:
|
|
304
304
|
cookbook_path: Path to Chef cookbook or cookbooks directory
|
|
@@ -325,7 +325,7 @@ def analyze_cookbook_dependencies(
|
|
|
325
325
|
)
|
|
326
326
|
|
|
327
327
|
# Analyze dependencies
|
|
328
|
-
dependency_analysis =
|
|
328
|
+
dependency_analysis = _analyse_cookbook_dependencies_detailed(cookbook_path_obj)
|
|
329
329
|
|
|
330
330
|
# Determine migration order
|
|
331
331
|
migration_order = _determine_migration_order(dependency_analysis)
|
|
@@ -356,7 +356,7 @@ def analyze_cookbook_dependencies(
|
|
|
356
356
|
{_format_community_cookbooks(dependency_analysis)}
|
|
357
357
|
|
|
358
358
|
## Migration Impact Analysis:
|
|
359
|
-
{
|
|
359
|
+
{_analyse_dependency_migration_impact(dependency_analysis)}
|
|
360
360
|
"""
|
|
361
361
|
except Exception as e:
|
|
362
362
|
return format_error_with_context(
|
|
@@ -539,11 +539,11 @@ def _parse_cookbook_paths(cookbook_paths: str) -> list[Any]:
|
|
|
539
539
|
return valid_paths
|
|
540
540
|
|
|
541
541
|
|
|
542
|
-
def
|
|
542
|
+
def _analyse_cookbook_metrics(
|
|
543
543
|
valid_paths: list[Any],
|
|
544
544
|
) -> tuple[list[Any], dict[str, int]]:
|
|
545
545
|
"""
|
|
546
|
-
|
|
546
|
+
Analyse metrics for all cookbooks.
|
|
547
547
|
|
|
548
548
|
Args:
|
|
549
549
|
valid_paths: List of valid cookbook paths
|
|
@@ -656,8 +656,8 @@ def _count_cookbook_artifacts(cookbook_path) -> dict[str, int]:
|
|
|
656
656
|
}
|
|
657
657
|
|
|
658
658
|
|
|
659
|
-
def
|
|
660
|
-
"""
|
|
659
|
+
def _analyse_recipe_complexity(cookbook_path) -> dict[str, int]:
|
|
660
|
+
"""Analyse recipe files for resource counts, Ruby blocks, and custom resources."""
|
|
661
661
|
recipes_dir = _safe_join(cookbook_path, "recipes")
|
|
662
662
|
resource_count = 0
|
|
663
663
|
custom_resources = 0
|
|
@@ -741,7 +741,7 @@ def _assess_single_cookbook(cookbook_path: Path) -> dict:
|
|
|
741
741
|
|
|
742
742
|
# Collect metrics
|
|
743
743
|
artifact_counts = _count_cookbook_artifacts(cookbook)
|
|
744
|
-
recipe_complexity =
|
|
744
|
+
recipe_complexity = _analyse_recipe_complexity(cookbook)
|
|
745
745
|
metrics = {**artifact_counts, **recipe_complexity}
|
|
746
746
|
|
|
747
747
|
# Calculate complexity and effort
|
|
@@ -1025,7 +1025,7 @@ def _estimate_resource_requirements(metrics: dict, target_platform: str) -> str:
|
|
|
1025
1025
|
• **Training:** 2-3 days Ansible/AWX training for team"""
|
|
1026
1026
|
|
|
1027
1027
|
|
|
1028
|
-
def
|
|
1028
|
+
def _analyse_cookbook_dependencies_detailed(cookbook_path) -> dict:
|
|
1029
1029
|
"""Analyze cookbook dependencies in detail."""
|
|
1030
1030
|
analysis = {
|
|
1031
1031
|
"cookbook_name": cookbook_path.name,
|
|
@@ -1364,8 +1364,8 @@ def _format_community_cookbooks(analysis: dict) -> str:
|
|
|
1364
1364
|
)
|
|
1365
1365
|
|
|
1366
1366
|
|
|
1367
|
-
def
|
|
1368
|
-
"""
|
|
1367
|
+
def _analyse_dependency_migration_impact(analysis: dict) -> str:
|
|
1368
|
+
"""Analyse migration impact of dependencies."""
|
|
1369
1369
|
impacts = []
|
|
1370
1370
|
|
|
1371
1371
|
if analysis["community_cookbooks"]:
|
|
@@ -52,8 +52,8 @@ def generate_github_workflow_from_chef_ci(
|
|
|
52
52
|
if not cookbook_dir.exists():
|
|
53
53
|
raise FileNotFoundError(f"Cookbook directory not found: {cookbook_path}")
|
|
54
54
|
|
|
55
|
-
#
|
|
56
|
-
patterns =
|
|
55
|
+
# Analyse Chef CI patterns
|
|
56
|
+
patterns = _analyse_chef_ci_patterns(cookbook_dir)
|
|
57
57
|
|
|
58
58
|
# Build workflow structure
|
|
59
59
|
workflow = _build_workflow_structure(
|
|
@@ -63,16 +63,16 @@ def generate_github_workflow_from_chef_ci(
|
|
|
63
63
|
return yaml.dump(workflow, default_flow_style=False, sort_keys=False)
|
|
64
64
|
|
|
65
65
|
|
|
66
|
-
def
|
|
66
|
+
def _analyse_chef_ci_patterns(cookbook_dir: Path) -> dict[str, Any]:
|
|
67
67
|
"""
|
|
68
|
-
|
|
68
|
+
Analyse Chef cookbook for CI/CD patterns and testing configurations.
|
|
69
69
|
|
|
70
70
|
This function examines a Chef cookbook directory to detect various
|
|
71
71
|
testing and linting tools, as well as Test Kitchen configurations
|
|
72
72
|
including suites and platforms.
|
|
73
73
|
|
|
74
74
|
Args:
|
|
75
|
-
cookbook_dir: Path to the Chef cookbook directory to
|
|
75
|
+
cookbook_dir: Path to the Chef cookbook directory to analyse.
|
|
76
76
|
|
|
77
77
|
Returns:
|
|
78
78
|
Dictionary containing detected patterns with the following keys:
|
|
@@ -27,8 +27,8 @@ def generate_gitlab_ci_from_chef_ci(
|
|
|
27
27
|
GitLab CI YAML content.
|
|
28
28
|
|
|
29
29
|
"""
|
|
30
|
-
#
|
|
31
|
-
ci_patterns =
|
|
30
|
+
# Analyse Chef CI patterns
|
|
31
|
+
ci_patterns = _analyse_chef_ci_patterns(cookbook_path)
|
|
32
32
|
|
|
33
33
|
# Generate CI configuration
|
|
34
34
|
return _generate_gitlab_ci_yaml(
|
|
@@ -36,9 +36,9 @@ def generate_gitlab_ci_from_chef_ci(
|
|
|
36
36
|
)
|
|
37
37
|
|
|
38
38
|
|
|
39
|
-
def
|
|
39
|
+
def _analyse_chef_ci_patterns(cookbook_path: str) -> dict[str, Any]:
|
|
40
40
|
"""
|
|
41
|
-
|
|
41
|
+
Analyse Chef cookbook for CI/CD patterns.
|
|
42
42
|
|
|
43
43
|
Args:
|
|
44
44
|
cookbook_path: Path to Chef cookbook.
|
|
@@ -28,8 +28,8 @@ def generate_jenkinsfile_from_chef_ci(
|
|
|
28
28
|
Jenkinsfile content (Groovy DSL).
|
|
29
29
|
|
|
30
30
|
"""
|
|
31
|
-
#
|
|
32
|
-
ci_patterns =
|
|
31
|
+
# Analyse Chef CI patterns
|
|
32
|
+
ci_patterns = _analyse_chef_ci_patterns(cookbook_path)
|
|
33
33
|
|
|
34
34
|
if pipeline_type == "declarative":
|
|
35
35
|
return _generate_declarative_pipeline(
|
|
@@ -39,9 +39,9 @@ def generate_jenkinsfile_from_chef_ci(
|
|
|
39
39
|
return _generate_scripted_pipeline(pipeline_name, enable_parallel)
|
|
40
40
|
|
|
41
41
|
|
|
42
|
-
def
|
|
42
|
+
def _analyse_chef_ci_patterns(cookbook_path: str) -> dict[str, Any]:
|
|
43
43
|
"""
|
|
44
|
-
|
|
44
|
+
Analyse Chef cookbook for CI/CD patterns.
|
|
45
45
|
|
|
46
46
|
Detects:
|
|
47
47
|
- Test Kitchen configuration (.kitchen.yml)
|