kinetic-devops 0.1.0a1__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.
- kinetic_devops-0.1.0a1/LICENSE +73 -0
- kinetic_devops-0.1.0a1/PKG-INFO +231 -0
- kinetic_devops-0.1.0a1/README.md +207 -0
- kinetic_devops-0.1.0a1/kinetic_devops/KineticCore.py +364 -0
- kinetic_devops-0.1.0a1/kinetic_devops/__init__.py +44 -0
- kinetic_devops-0.1.0a1/kinetic_devops/__main__.py +59 -0
- kinetic_devops-0.1.0a1/kinetic_devops/auth.py +1323 -0
- kinetic_devops-0.1.0a1/kinetic_devops/baq.py +88 -0
- kinetic_devops-0.1.0a1/kinetic_devops/base_client.py +357 -0
- kinetic_devops-0.1.0a1/kinetic_devops/boreader.py +129 -0
- kinetic_devops-0.1.0a1/kinetic_devops/cli/__init__.py +5 -0
- kinetic_devops-0.1.0a1/kinetic_devops/cli/test_runner.py +63 -0
- kinetic_devops-0.1.0a1/kinetic_devops/crypto.py +74 -0
- kinetic_devops-0.1.0a1/kinetic_devops/efx.py +86 -0
- kinetic_devops-0.1.0a1/kinetic_devops/export_all.py +687 -0
- kinetic_devops-0.1.0a1/kinetic_devops/file_service.py +345 -0
- kinetic_devops-0.1.0a1/kinetic_devops/find_sensitive_data.py +549 -0
- kinetic_devops-0.1.0a1/kinetic_devops/fs_ops.py +273 -0
- kinetic_devops-0.1.0a1/kinetic_devops/metafx.py +378 -0
- kinetic_devops-0.1.0a1/kinetic_devops/report_service.py +125 -0
- kinetic_devops-0.1.0a1/kinetic_devops/solutions.py +932 -0
- kinetic_devops-0.1.0a1/kinetic_devops/tax_service.py +214 -0
- kinetic_devops-0.1.0a1/kinetic_devops/zdatatable.py +293 -0
- kinetic_devops-0.1.0a1/kinetic_devops.egg-info/PKG-INFO +231 -0
- kinetic_devops-0.1.0a1/kinetic_devops.egg-info/SOURCES.txt +40 -0
- kinetic_devops-0.1.0a1/kinetic_devops.egg-info/dependency_links.txt +1 -0
- kinetic_devops-0.1.0a1/kinetic_devops.egg-info/requires.txt +2 -0
- kinetic_devops-0.1.0a1/kinetic_devops.egg-info/top_level.txt +1 -0
- kinetic_devops-0.1.0a1/pyproject.toml +38 -0
- kinetic_devops-0.1.0a1/setup.cfg +4 -0
- kinetic_devops-0.1.0a1/tests/test_base_client_redaction.py +141 -0
- kinetic_devops-0.1.0a1/tests/test_cli.py +45 -0
- kinetic_devops-0.1.0a1/tests/test_export_all.py +80 -0
- kinetic_devops-0.1.0a1/tests/test_file_resolution.py +125 -0
- kinetic_devops-0.1.0a1/tests/test_fs_ops.py +148 -0
- kinetic_devops-0.1.0a1/tests/test_imports.py +67 -0
- kinetic_devops-0.1.0a1/tests/test_redaction.py +77 -0
- kinetic_devops-0.1.0a1/tests/test_runner.py +146 -0
- kinetic_devops-0.1.0a1/tests/test_sensitive_data_scan_exclusions.py +110 -0
- kinetic_devops-0.1.0a1/tests/test_services.py +62 -0
- kinetic_devops-0.1.0a1/tests/test_solutions.py +184 -0
- kinetic_devops-0.1.0a1/tests/test_zdatatable.py +60 -0
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
|
|
10
|
+
|
|
11
|
+
"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
|
|
12
|
+
|
|
13
|
+
"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
|
|
14
|
+
|
|
15
|
+
"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
|
|
16
|
+
|
|
17
|
+
"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
|
|
18
|
+
|
|
19
|
+
"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
|
|
20
|
+
|
|
21
|
+
"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
|
|
22
|
+
|
|
23
|
+
"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
|
|
24
|
+
|
|
25
|
+
"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
|
|
26
|
+
|
|
27
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
|
|
28
|
+
|
|
29
|
+
2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
|
|
30
|
+
|
|
31
|
+
3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
|
|
32
|
+
|
|
33
|
+
4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
|
|
34
|
+
|
|
35
|
+
(a) You must give any other recipients of the Work or Derivative Works a copy of this License; and
|
|
36
|
+
|
|
37
|
+
(b) You must cause any modified files to carry prominent notices stating that You changed the files; and
|
|
38
|
+
|
|
39
|
+
(c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
|
|
40
|
+
|
|
41
|
+
(d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.
|
|
42
|
+
|
|
43
|
+
You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
|
|
44
|
+
|
|
45
|
+
5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
|
|
46
|
+
|
|
47
|
+
6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
|
|
48
|
+
|
|
49
|
+
7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
|
|
50
|
+
|
|
51
|
+
8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
|
|
52
|
+
|
|
53
|
+
9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
|
|
54
|
+
|
|
55
|
+
END OF TERMS AND CONDITIONS
|
|
56
|
+
|
|
57
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
58
|
+
|
|
59
|
+
To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives.
|
|
60
|
+
|
|
61
|
+
Copyright 2026 Steffes-Epicor
|
|
62
|
+
|
|
63
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
64
|
+
you may not use this file except in compliance with the License.
|
|
65
|
+
You may obtain a copy of the License at
|
|
66
|
+
|
|
67
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
68
|
+
|
|
69
|
+
Unless required by applicable law or agreed to in writing, software
|
|
70
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
71
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
72
|
+
See the License for the specific language governing permissions and
|
|
73
|
+
limitations under the License.
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: kinetic-devops
|
|
3
|
+
Version: 0.1.0a1
|
|
4
|
+
Summary: Python toolkit for Epicor Kinetic environment management, CI/CD automation, and data migration workflows.
|
|
5
|
+
Author: Kinetic DevOps Contributors
|
|
6
|
+
License-Expression: Apache-2.0
|
|
7
|
+
Classifier: Development Status :: 3 - Alpha
|
|
8
|
+
Classifier: Intended Audience :: Developers
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
17
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
18
|
+
Requires-Python: >=3.8
|
|
19
|
+
Description-Content-Type: text/markdown
|
|
20
|
+
License-File: LICENSE
|
|
21
|
+
Requires-Dist: keyring
|
|
22
|
+
Requires-Dist: requests
|
|
23
|
+
Dynamic: license-file
|
|
24
|
+
|
|
25
|
+
# Kinetic DevOps
|
|
26
|
+
|
|
27
|
+
**Status: ⚠️ ALPHA** — Early development. API and features may change significantly.
|
|
28
|
+
|
|
29
|
+
**Kinetic DevOps** is a Python SDK and automation framework designed to bring modern DevOps practices to the Epicor Kinetic ecosystem. It provides a secure, extensible, and consistent foundation for environment management, CI/CD pipelines, and complex data migration workflows.
|
|
30
|
+
|
|
31
|
+
## Features
|
|
32
|
+
|
|
33
|
+
- 🔐 **Secure credential management** — OS keyring-backed encryption, no plaintext secrets
|
|
34
|
+
- 🔄 **Multi-environment support** — Seamlessly switch between Dev/Test/Prod
|
|
35
|
+
- 🛠️ **Ready-to-use Service Clients** — High-level clients for BAQ, BOReader, Reports, Tax, and more, built on a robust base client with wire logging and data redaction.
|
|
36
|
+
- 🚀 **Extensible Project Templates** — A "batteries-included" project structure with auto-discovery for creating your own reusable functions, layers, and scheduled jobs.
|
|
37
|
+
- 🤖 **CI/CD Ready** — Designed for automation with environment variable support, programmatic APIs, and pre-commit hooks for local validation.
|
|
38
|
+
- 📜 **Powerful CLI Tools** — Includes helper scripts for environment initialization, health validation, and common administrative tasks like configuration syncing.
|
|
39
|
+
- 🧩 **Layer Lifecycle Operations** — Native MetaFX support for core layer import/delete operations (`ImportLayers` / `BulkDeleteLayers`) with structured error reports.
|
|
40
|
+
- 🤖 **CI/CD ready** — Environment variables, programmatic API, pre-commit hooks
|
|
41
|
+
- 📦 **Modular architecture** — Extend with custom project submodules
|
|
42
|
+
|
|
43
|
+
## Quick Start
|
|
44
|
+
|
|
45
|
+
### Windows PowerShell
|
|
46
|
+
```powershell
|
|
47
|
+
.\scripts\env_init.ps1
|
|
48
|
+
python -m kinetic_devops.auth store
|
|
49
|
+
python scripts/validate.py
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
### Linux/macOS
|
|
53
|
+
```bash
|
|
54
|
+
python scripts/env_init.py
|
|
55
|
+
python -m kinetic_devops.auth store
|
|
56
|
+
python scripts/validate.py
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Usage
|
|
60
|
+
|
|
61
|
+
```python
|
|
62
|
+
from kinetic_devops.auth import KineticConfigManager
|
|
63
|
+
from kinetic_devops.baq import BAQClient
|
|
64
|
+
|
|
65
|
+
# Initialize authentication
|
|
66
|
+
config = KineticConfigManager()
|
|
67
|
+
|
|
68
|
+
# Create BAQ client (handles session, headers, requests)
|
|
69
|
+
baq_client = BAQClient(config)
|
|
70
|
+
|
|
71
|
+
# Execute a BAQ
|
|
72
|
+
results = baq_client.execute_baq(
|
|
73
|
+
baq_id='CUST_List',
|
|
74
|
+
args={'Company': 'ABC', 'MaxResults': 100}
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
# Process results
|
|
78
|
+
for customer in results['value']:
|
|
79
|
+
print(f"{customer['CustomerID']}: {customer['CustomerName']}")
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### MetaFX Layer DevOps Flow
|
|
83
|
+
|
|
84
|
+
```powershell
|
|
85
|
+
# Dry-run: parse dump files and resolve layer operations without sending requests
|
|
86
|
+
python -m kinetic_devops meta --env <ENV> --user <USER> layers "C:/path/dump (5).json" "C:/path/dump (6).json" --dry-run
|
|
87
|
+
|
|
88
|
+
# Execute: run import/delete operations and capture status + correlation IDs in a report
|
|
89
|
+
python -m kinetic_devops meta --env <ENV> --user <USER> layers "C:/path/dump (5).json" "C:/path/dump (6).json" --report temp/layer_ops_report.json
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Default behavior for `layers` is deployment mode (`--ops import`):
|
|
93
|
+
- Executes delete operations first (when present)
|
|
94
|
+
- Then executes import operations
|
|
95
|
+
|
|
96
|
+
This flow is designed to support layer deployment and rollback as part of the DevOps cycle.
|
|
97
|
+
|
|
98
|
+
### ExportAllTheThings Full Export Flow
|
|
99
|
+
|
|
100
|
+
Export everything currently exposed by your ExportAllTheThings library:
|
|
101
|
+
|
|
102
|
+
```powershell
|
|
103
|
+
# Export all discovered Export* functions and write a manifest
|
|
104
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --library ExportAllTheThings --out-dir exports/ExportAllTheThings
|
|
105
|
+
|
|
106
|
+
# List discovered export functions only
|
|
107
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --list
|
|
108
|
+
|
|
109
|
+
# Run one export function
|
|
110
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --function ExportAllCustomBAQs
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
The export command:
|
|
114
|
+
- Discovers export-capable functions from the EFx library (FunctionID starts with Export)
|
|
115
|
+
- Executes one or all exports
|
|
116
|
+
- Saves each artifact file
|
|
117
|
+
- Writes an export manifest JSON with per-function success/failure details
|
|
118
|
+
|
|
119
|
+
Mode behavior:
|
|
120
|
+
- `--mode auto` (default): uses ExportAllTheThings when present, otherwise native endpoints
|
|
121
|
+
- `--mode eatt`: requires EFx export library behavior
|
|
122
|
+
- `--mode native`: no ExportAllTheThings dependency
|
|
123
|
+
|
|
124
|
+
Native examples (no ExportAllTheThings required):
|
|
125
|
+
|
|
126
|
+
```powershell
|
|
127
|
+
# Run built-in native export plan for BAQs, directives, UD codes, MetaFX app list, etc.
|
|
128
|
+
python -m kinetic_devops export --mode native --env <ENV> --user <USER> --out-dir exports/native
|
|
129
|
+
|
|
130
|
+
# Pull one endpoint at a time
|
|
131
|
+
python -m kinetic_devops export --mode native --env <ENV> --user <USER> --native-endpoint "/api/v2/odata/{company}/Ice.BO.BAQDesignerSvc/GetList" --native-method POST --native-body '{"whereClause":"SystemFlag=false","pageSize":0,"absolutePage":0}' --native-name baq_list_single
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
### Solution Workbench Backup And Recreate
|
|
135
|
+
|
|
136
|
+
Solution migration is a different workflow from package build/install.
|
|
137
|
+
|
|
138
|
+
- `BuildSolution` and `InstallSolution` operate on a built package artifact
|
|
139
|
+
- `GetByID`, `GetNewExportPackage`, and `Update` operate on the solution definition dataset
|
|
140
|
+
- Recreating the solution in the target environment lets you build it there later
|
|
141
|
+
|
|
142
|
+
Typical operational sequence:
|
|
143
|
+
- `create` in Kinetic UI (author/edit your solution)
|
|
144
|
+
- `backup` in DevOps
|
|
145
|
+
- `build` in DevOps (when you need a package artifact)
|
|
146
|
+
- `install` in DevOps (when promoting by package)
|
|
147
|
+
- `recreate` in DevOps (when migrating editable solution definition state)
|
|
148
|
+
|
|
149
|
+
You can use package promotion (`build` + `install`) and definition migration (`recreate`) independently or together.
|
|
150
|
+
|
|
151
|
+
Examples:
|
|
152
|
+
|
|
153
|
+
```powershell
|
|
154
|
+
# Back up a solution definition and its tracked-item snapshots
|
|
155
|
+
python -m kinetic_devops solutions --env <SOURCE_ENV> --user <USER> backup MySolution --out-dir exports/solutions
|
|
156
|
+
|
|
157
|
+
# Recreate that solution definition in a target environment
|
|
158
|
+
python -m kinetic_devops solutions --env <TARGET_ENV> --user <USER> recreate exports/solutions/solution_backup_MySolution_20260331T000000Z.json
|
|
159
|
+
|
|
160
|
+
# Recreate under a new Solution ID, replacing an existing target solution if needed
|
|
161
|
+
python -m kinetic_devops solutions --env <TARGET_ENV> --user <USER> recreate exports/solutions/solution_backup_MySolution_20260331T000000Z.json --target-solution-id MySolution_Copy --overwrite
|
|
162
|
+
|
|
163
|
+
# Build a CAB package from a solution on the server
|
|
164
|
+
python -m kinetic_devops solutions --env <ENV> --user <USER> build MySolution
|
|
165
|
+
|
|
166
|
+
# Install a CAB package
|
|
167
|
+
python -m kinetic_devops solutions --env <ENV> --user <USER> install temp/MySolution.cab
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
Current recreate behavior is intentionally focused on the Solution Workbench definition:
|
|
171
|
+
- solution header and package rows
|
|
172
|
+
- solution detail membership rows
|
|
173
|
+
- backup capture of per-table dynamic/tracked snapshots for later analysis
|
|
174
|
+
|
|
175
|
+
`recreate` does not implicitly call `build` or `install`; those are explicit steps.
|
|
176
|
+
|
|
177
|
+
See [examples/complete_flow.py](examples/complete_flow.py) for a complete auth → BAQ → results example.
|
|
178
|
+
|
|
179
|
+
## Documentation
|
|
180
|
+
|
|
181
|
+
- [ARCHITECTURE.md](Documents/ARCHITECTURE.md) — Design principles, workflow examples
|
|
182
|
+
- [scripts/README.md](scripts/README.md) — Helper scripts reference
|
|
183
|
+
- [tests/README.md](tests/README.md) — Test suite documentation
|
|
184
|
+
|
|
185
|
+
## Known Limitations
|
|
186
|
+
|
|
187
|
+
- **Alpha stage** — Breaking changes may occur between versions
|
|
188
|
+
- **Redaction edge cases** — Heuristic-based sensitive data masking has known gaps
|
|
189
|
+
- **Windows-first** — Tested primarily on Windows; Linux/macOS support improving
|
|
190
|
+
|
|
191
|
+
## Project Structure
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
kinetic-devops/ # Core library (published)
|
|
195
|
+
├── kinetic_devops/ # Main package
|
|
196
|
+
├── scripts/ # Helper scripts
|
|
197
|
+
├── tests/ # Test suite
|
|
198
|
+
└── projects/ # (Optional) User project submodules
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
Users extend this core by adding private Git submodules for their custom implementations.
|
|
202
|
+
|
|
203
|
+
## Requirements
|
|
204
|
+
|
|
205
|
+
- Python 3.8+
|
|
206
|
+
- `keyring` — Secure credential storage
|
|
207
|
+
- `requests` — HTTP client
|
|
208
|
+
|
|
209
|
+
## Installation
|
|
210
|
+
|
|
211
|
+
Using `uv` (recommended):
|
|
212
|
+
```bash
|
|
213
|
+
uv pip install kinetic-devops
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
Or with pip:
|
|
217
|
+
```bash
|
|
218
|
+
pip install kinetic-devops
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
From source with `uv`:
|
|
222
|
+
```bash
|
|
223
|
+
git clone https://github.com/your-org/kinetic-devops.git
|
|
224
|
+
cd kinetic-devops
|
|
225
|
+
uv sync
|
|
226
|
+
uv pip install -e .
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
## License
|
|
230
|
+
|
|
231
|
+
See [LICENSE](LICENSE) file.
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
# Kinetic DevOps
|
|
2
|
+
|
|
3
|
+
**Status: ⚠️ ALPHA** — Early development. API and features may change significantly.
|
|
4
|
+
|
|
5
|
+
**Kinetic DevOps** is a Python SDK and automation framework designed to bring modern DevOps practices to the Epicor Kinetic ecosystem. It provides a secure, extensible, and consistent foundation for environment management, CI/CD pipelines, and complex data migration workflows.
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- 🔐 **Secure credential management** — OS keyring-backed encryption, no plaintext secrets
|
|
10
|
+
- 🔄 **Multi-environment support** — Seamlessly switch between Dev/Test/Prod
|
|
11
|
+
- 🛠️ **Ready-to-use Service Clients** — High-level clients for BAQ, BOReader, Reports, Tax, and more, built on a robust base client with wire logging and data redaction.
|
|
12
|
+
- 🚀 **Extensible Project Templates** — A "batteries-included" project structure with auto-discovery for creating your own reusable functions, layers, and scheduled jobs.
|
|
13
|
+
- 🤖 **CI/CD Ready** — Designed for automation with environment variable support, programmatic APIs, and pre-commit hooks for local validation.
|
|
14
|
+
- 📜 **Powerful CLI Tools** — Includes helper scripts for environment initialization, health validation, and common administrative tasks like configuration syncing.
|
|
15
|
+
- 🧩 **Layer Lifecycle Operations** — Native MetaFX support for core layer import/delete operations (`ImportLayers` / `BulkDeleteLayers`) with structured error reports.
|
|
16
|
+
- 🤖 **CI/CD ready** — Environment variables, programmatic API, pre-commit hooks
|
|
17
|
+
- 📦 **Modular architecture** — Extend with custom project submodules
|
|
18
|
+
|
|
19
|
+
## Quick Start
|
|
20
|
+
|
|
21
|
+
### Windows PowerShell
|
|
22
|
+
```powershell
|
|
23
|
+
.\scripts\env_init.ps1
|
|
24
|
+
python -m kinetic_devops.auth store
|
|
25
|
+
python scripts/validate.py
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
### Linux/macOS
|
|
29
|
+
```bash
|
|
30
|
+
python scripts/env_init.py
|
|
31
|
+
python -m kinetic_devops.auth store
|
|
32
|
+
python scripts/validate.py
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Usage
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
from kinetic_devops.auth import KineticConfigManager
|
|
39
|
+
from kinetic_devops.baq import BAQClient
|
|
40
|
+
|
|
41
|
+
# Initialize authentication
|
|
42
|
+
config = KineticConfigManager()
|
|
43
|
+
|
|
44
|
+
# Create BAQ client (handles session, headers, requests)
|
|
45
|
+
baq_client = BAQClient(config)
|
|
46
|
+
|
|
47
|
+
# Execute a BAQ
|
|
48
|
+
results = baq_client.execute_baq(
|
|
49
|
+
baq_id='CUST_List',
|
|
50
|
+
args={'Company': 'ABC', 'MaxResults': 100}
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
# Process results
|
|
54
|
+
for customer in results['value']:
|
|
55
|
+
print(f"{customer['CustomerID']}: {customer['CustomerName']}")
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### MetaFX Layer DevOps Flow
|
|
59
|
+
|
|
60
|
+
```powershell
|
|
61
|
+
# Dry-run: parse dump files and resolve layer operations without sending requests
|
|
62
|
+
python -m kinetic_devops meta --env <ENV> --user <USER> layers "C:/path/dump (5).json" "C:/path/dump (6).json" --dry-run
|
|
63
|
+
|
|
64
|
+
# Execute: run import/delete operations and capture status + correlation IDs in a report
|
|
65
|
+
python -m kinetic_devops meta --env <ENV> --user <USER> layers "C:/path/dump (5).json" "C:/path/dump (6).json" --report temp/layer_ops_report.json
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
Default behavior for `layers` is deployment mode (`--ops import`):
|
|
69
|
+
- Executes delete operations first (when present)
|
|
70
|
+
- Then executes import operations
|
|
71
|
+
|
|
72
|
+
This flow is designed to support layer deployment and rollback as part of the DevOps cycle.
|
|
73
|
+
|
|
74
|
+
### ExportAllTheThings Full Export Flow
|
|
75
|
+
|
|
76
|
+
Export everything currently exposed by your ExportAllTheThings library:
|
|
77
|
+
|
|
78
|
+
```powershell
|
|
79
|
+
# Export all discovered Export* functions and write a manifest
|
|
80
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --library ExportAllTheThings --out-dir exports/ExportAllTheThings
|
|
81
|
+
|
|
82
|
+
# List discovered export functions only
|
|
83
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --list
|
|
84
|
+
|
|
85
|
+
# Run one export function
|
|
86
|
+
python -m kinetic_devops export --env <ENV> --user <USER> --function ExportAllCustomBAQs
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
The export command:
|
|
90
|
+
- Discovers export-capable functions from the EFx library (FunctionID starts with Export)
|
|
91
|
+
- Executes one or all exports
|
|
92
|
+
- Saves each artifact file
|
|
93
|
+
- Writes an export manifest JSON with per-function success/failure details
|
|
94
|
+
|
|
95
|
+
Mode behavior:
|
|
96
|
+
- `--mode auto` (default): uses ExportAllTheThings when present, otherwise native endpoints
|
|
97
|
+
- `--mode eatt`: requires EFx export library behavior
|
|
98
|
+
- `--mode native`: no ExportAllTheThings dependency
|
|
99
|
+
|
|
100
|
+
Native examples (no ExportAllTheThings required):
|
|
101
|
+
|
|
102
|
+
```powershell
|
|
103
|
+
# Run built-in native export plan for BAQs, directives, UD codes, MetaFX app list, etc.
|
|
104
|
+
python -m kinetic_devops export --mode native --env <ENV> --user <USER> --out-dir exports/native
|
|
105
|
+
|
|
106
|
+
# Pull one endpoint at a time
|
|
107
|
+
python -m kinetic_devops export --mode native --env <ENV> --user <USER> --native-endpoint "/api/v2/odata/{company}/Ice.BO.BAQDesignerSvc/GetList" --native-method POST --native-body '{"whereClause":"SystemFlag=false","pageSize":0,"absolutePage":0}' --native-name baq_list_single
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
### Solution Workbench Backup And Recreate
|
|
111
|
+
|
|
112
|
+
Solution migration is a different workflow from package build/install.
|
|
113
|
+
|
|
114
|
+
- `BuildSolution` and `InstallSolution` operate on a built package artifact
|
|
115
|
+
- `GetByID`, `GetNewExportPackage`, and `Update` operate on the solution definition dataset
|
|
116
|
+
- Recreating the solution in the target environment lets you build it there later
|
|
117
|
+
|
|
118
|
+
Typical operational sequence:
|
|
119
|
+
- `create` in Kinetic UI (author/edit your solution)
|
|
120
|
+
- `backup` in DevOps
|
|
121
|
+
- `build` in DevOps (when you need a package artifact)
|
|
122
|
+
- `install` in DevOps (when promoting by package)
|
|
123
|
+
- `recreate` in DevOps (when migrating editable solution definition state)
|
|
124
|
+
|
|
125
|
+
You can use package promotion (`build` + `install`) and definition migration (`recreate`) independently or together.
|
|
126
|
+
|
|
127
|
+
Examples:
|
|
128
|
+
|
|
129
|
+
```powershell
|
|
130
|
+
# Back up a solution definition and its tracked-item snapshots
|
|
131
|
+
python -m kinetic_devops solutions --env <SOURCE_ENV> --user <USER> backup MySolution --out-dir exports/solutions
|
|
132
|
+
|
|
133
|
+
# Recreate that solution definition in a target environment
|
|
134
|
+
python -m kinetic_devops solutions --env <TARGET_ENV> --user <USER> recreate exports/solutions/solution_backup_MySolution_20260331T000000Z.json
|
|
135
|
+
|
|
136
|
+
# Recreate under a new Solution ID, replacing an existing target solution if needed
|
|
137
|
+
python -m kinetic_devops solutions --env <TARGET_ENV> --user <USER> recreate exports/solutions/solution_backup_MySolution_20260331T000000Z.json --target-solution-id MySolution_Copy --overwrite
|
|
138
|
+
|
|
139
|
+
# Build a CAB package from a solution on the server
|
|
140
|
+
python -m kinetic_devops solutions --env <ENV> --user <USER> build MySolution
|
|
141
|
+
|
|
142
|
+
# Install a CAB package
|
|
143
|
+
python -m kinetic_devops solutions --env <ENV> --user <USER> install temp/MySolution.cab
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
Current recreate behavior is intentionally focused on the Solution Workbench definition:
|
|
147
|
+
- solution header and package rows
|
|
148
|
+
- solution detail membership rows
|
|
149
|
+
- backup capture of per-table dynamic/tracked snapshots for later analysis
|
|
150
|
+
|
|
151
|
+
`recreate` does not implicitly call `build` or `install`; those are explicit steps.
|
|
152
|
+
|
|
153
|
+
See [examples/complete_flow.py](examples/complete_flow.py) for a complete auth → BAQ → results example.
|
|
154
|
+
|
|
155
|
+
## Documentation
|
|
156
|
+
|
|
157
|
+
- [ARCHITECTURE.md](Documents/ARCHITECTURE.md) — Design principles, workflow examples
|
|
158
|
+
- [scripts/README.md](scripts/README.md) — Helper scripts reference
|
|
159
|
+
- [tests/README.md](tests/README.md) — Test suite documentation
|
|
160
|
+
|
|
161
|
+
## Known Limitations
|
|
162
|
+
|
|
163
|
+
- **Alpha stage** — Breaking changes may occur between versions
|
|
164
|
+
- **Redaction edge cases** — Heuristic-based sensitive data masking has known gaps
|
|
165
|
+
- **Windows-first** — Tested primarily on Windows; Linux/macOS support improving
|
|
166
|
+
|
|
167
|
+
## Project Structure
|
|
168
|
+
|
|
169
|
+
```
|
|
170
|
+
kinetic-devops/ # Core library (published)
|
|
171
|
+
├── kinetic_devops/ # Main package
|
|
172
|
+
├── scripts/ # Helper scripts
|
|
173
|
+
├── tests/ # Test suite
|
|
174
|
+
└── projects/ # (Optional) User project submodules
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
Users extend this core by adding private Git submodules for their custom implementations.
|
|
178
|
+
|
|
179
|
+
## Requirements
|
|
180
|
+
|
|
181
|
+
- Python 3.8+
|
|
182
|
+
- `keyring` — Secure credential storage
|
|
183
|
+
- `requests` — HTTP client
|
|
184
|
+
|
|
185
|
+
## Installation
|
|
186
|
+
|
|
187
|
+
Using `uv` (recommended):
|
|
188
|
+
```bash
|
|
189
|
+
uv pip install kinetic-devops
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
Or with pip:
|
|
193
|
+
```bash
|
|
194
|
+
pip install kinetic-devops
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
From source with `uv`:
|
|
198
|
+
```bash
|
|
199
|
+
git clone https://github.com/your-org/kinetic-devops.git
|
|
200
|
+
cd kinetic-devops
|
|
201
|
+
uv sync
|
|
202
|
+
uv pip install -e .
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
## License
|
|
206
|
+
|
|
207
|
+
See [LICENSE](LICENSE) file.
|