sdtk-ops-kit 0.3.4 → 0.4.0

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.
Files changed (36) hide show
  1. package/README.md +2 -1
  2. package/assets/manifest/toolkit-bundle.manifest.json +133 -13
  3. package/assets/manifest/toolkit-bundle.sha256.txt +31 -7
  4. package/assets/toolkit/toolkit/AGENTS.md +2 -1
  5. package/assets/toolkit/toolkit/SDTKOPS_TOOLKIT.md +4 -2
  6. package/assets/toolkit/toolkit/scripts/install-claude-skills.ps1 +4 -4
  7. package/assets/toolkit/toolkit/scripts/install-codex-skills.ps1 +4 -4
  8. package/assets/toolkit/toolkit/scripts/uninstall-claude-skills.ps1 +2 -2
  9. package/assets/toolkit/toolkit/scripts/uninstall-codex-skills.ps1 +2 -2
  10. package/assets/toolkit/toolkit/skills/ops-discover/SKILL.md +2 -0
  11. package/assets/toolkit/toolkit/skills/ops-local-env/SKILL.md +172 -0
  12. package/assets/toolkit/toolkit/skills/ops-local-env/references/CLUSTER_CA.md +83 -0
  13. package/assets/toolkit/toolkit/skills/ops-local-env/references/GOTCHAS.md +17 -0
  14. package/assets/toolkit/toolkit/skills/ops-local-env/references/K3D_CILIUM_BOOTSTRAP.md +39 -0
  15. package/assets/toolkit/toolkit/skills/ops-local-env/references/PROFILE.md +44 -0
  16. package/assets/toolkit/toolkit/skills/ops-local-env/references/bootstrap/cilium-values.yaml +37 -0
  17. package/assets/toolkit/toolkit/skills/ops-local-env/references/bootstrap/k3d-cluster.yaml +37 -0
  18. package/assets/toolkit/toolkit/skills/ops-local-env/references/profile.example.json +80 -0
  19. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/admin_creds.py +212 -0
  20. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/cilium_heal.py +136 -0
  21. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/ensure_repos.py +69 -0
  22. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/envprofile.py +139 -0
  23. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/explain_config.py +116 -0
  24. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/health.py +109 -0
  25. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/hosts_entry.py +158 -0
  26. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/init_profile.py +217 -0
  27. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/k3d_images.py +70 -0
  28. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/preflight.py +96 -0
  29. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/registry_secret.py +64 -0
  30. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/shared_config.py +178 -0
  31. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/stack_plan.py +94 -0
  32. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/teardown.py +86 -0
  33. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/test_local_env.py +307 -0
  34. package/assets/toolkit/toolkit/skills/ops-local-env/scripts/trust_ca.py +153 -0
  35. package/package.json +1 -1
  36. package/src/lib/scope.js +1 -0
package/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  ## Package
6
6
 
7
7
  - Package: `sdtk-ops-kit`
8
- - Version in this source snapshot: `0.3.4`
8
+ - Version in this source snapshot: `0.4.0`
9
9
  - CLI: `sdtk-ops`
10
10
  - Latest published version lookup: `npm view sdtk-ops-kit version`
11
11
 
@@ -160,6 +160,7 @@ Canonical journeys:
160
160
  - monitoring: `ops-plan -> ops-monitor -> ops-verify`
161
161
  - backup or recovery: `ops-plan -> ops-backup -> ops-verify`
162
162
  - Framer template deploy: `ops-plan -> ops-framer-deploy -> ops-verify`
163
+ - local test environment: `ops-local-env -> ops-verify`
163
164
 
164
165
  Always close work with `ops-verify`.
165
166
 
@@ -1,12 +1,12 @@
1
1
  {
2
- "version": "0.3.4",
3
- "sourceCommit": "6896f2f26dfc5aee3f71751e869b80608e34ecb7",
4
- "fileCount": 45,
2
+ "version": "0.4.0",
3
+ "sourceCommit": "76581df584eed6354033c13a2f2e35e862a85dfe",
4
+ "fileCount": 69,
5
5
  "files": [
6
6
  {
7
7
  "path": "toolkit/AGENTS.md",
8
- "sha256": "77d09c309061991343ef7ae42181afb7b8f9684c74a3f3a10166c93dbcec6508",
9
- "size": 16553
8
+ "sha256": "d6efcedeecf65b215528c12499ed3eb494a7343ce225b80f97473bfcbecd4ea3",
9
+ "size": 16691
10
10
  },
11
11
  {
12
12
  "path": "toolkit/install.ps1",
@@ -15,22 +15,22 @@
15
15
  },
16
16
  {
17
17
  "path": "toolkit/scripts/install-claude-skills.ps1",
18
- "sha256": "53fddfb0424676929f72d844faa319f2e4eba9252f1c2c31fd8780c9a61f224a",
18
+ "sha256": "cbfbbb138ee15a1faf54b9ad018baf6e4181ed5696ee4400acc2bafa8d2e9314",
19
19
  "size": 2474
20
20
  },
21
21
  {
22
22
  "path": "toolkit/scripts/install-codex-skills.ps1",
23
- "sha256": "a3451bd0978790d2bca9eecce1f2ab79e9351c3e9ef4693d8e8e3f245db0d96f",
23
+ "sha256": "b1b25a1cf7d1798aec8fc047b483bb9f83c715f4e65d6ada3119720ebc44f262",
24
24
  "size": 4761
25
25
  },
26
26
  {
27
27
  "path": "toolkit/scripts/uninstall-claude-skills.ps1",
28
- "sha256": "61dd1e2c41cb7e09ef4e197c38989dc72a836bc663a40ddeeb099733f01261e3",
28
+ "sha256": "3ad6b2d7047b751e632f4a54d58e260b6d8a8d6ebd41f88f324b9cfbe665ecf4",
29
29
  "size": 1901
30
30
  },
31
31
  {
32
32
  "path": "toolkit/scripts/uninstall-codex-skills.ps1",
33
- "sha256": "092b5633861406e0e83fc62ecb261a678237197fd500933eb7a3d5915ed826e4",
33
+ "sha256": "dc99a6d0ec4c5f015f02280e61de913b41edc2ef0e36c77b9d7c4749359b97d1",
34
34
  "size": 2428
35
35
  },
36
36
  {
@@ -45,8 +45,8 @@
45
45
  },
46
46
  {
47
47
  "path": "toolkit/SDTKOPS_TOOLKIT.md",
48
- "sha256": "3ad54f730fefdc94e5107a49b3d4a64e4169b035ceae90a4830d6f48944b2177",
49
- "size": 8142
48
+ "sha256": "d6193777823244b3e161be6056f329b916ae97f29a6674f66f4aa2e14891bcff",
49
+ "size": 8367
50
50
  },
51
51
  {
52
52
  "path": "toolkit/skills/ops-backup/references/backup-script-patterns.md",
@@ -105,8 +105,8 @@
105
105
  },
106
106
  {
107
107
  "path": "toolkit/skills/ops-discover/SKILL.md",
108
- "sha256": "6f38c9b2ab972f272fb86e17926585a9a254a1c48c8454459a61315d4bd81d81",
109
- "size": 5617
108
+ "sha256": "389ceec83758728ada6ed3b4e9c102646084bc041b051b7d3da290a5ac55b78e",
109
+ "size": 5808
110
110
  },
111
111
  {
112
112
  "path": "toolkit/skills/ops-framer-deploy/framer-deploy.config.example.json",
@@ -183,6 +183,126 @@
183
183
  "sha256": "35eec623e41603dae0a1a328c1e6d822d2e1dc79a471f06bab3c1f3e2d552e53",
184
184
  "size": 4442
185
185
  },
186
+ {
187
+ "path": "toolkit/skills/ops-local-env/references/bootstrap/cilium-values.yaml",
188
+ "sha256": "639bf209d35cc8392c4beb76d9a367118a88babf570766d128d26df3ca133426",
189
+ "size": 1205
190
+ },
191
+ {
192
+ "path": "toolkit/skills/ops-local-env/references/bootstrap/k3d-cluster.yaml",
193
+ "sha256": "4fc9433ffa646d9789e1e6064eb5eb1fd71430141ae456a55a65ab278611b45c",
194
+ "size": 1128
195
+ },
196
+ {
197
+ "path": "toolkit/skills/ops-local-env/references/CLUSTER_CA.md",
198
+ "sha256": "11883fcfa1d9ca28d5a5b37bbb3c7e449aac4821b298195c3d8b9df812ab3446",
199
+ "size": 4155
200
+ },
201
+ {
202
+ "path": "toolkit/skills/ops-local-env/references/GOTCHAS.md",
203
+ "sha256": "5f11aaf849bfe0cf9ad061e3711fce2c09a2317f3118ca0f8020cd1b5cfafdb0",
204
+ "size": 3185
205
+ },
206
+ {
207
+ "path": "toolkit/skills/ops-local-env/references/K3D_CILIUM_BOOTSTRAP.md",
208
+ "sha256": "1d92cd11ef56944b07797071daa8b3d0f945f2e9e9822794d597115f3ae28884",
209
+ "size": 2273
210
+ },
211
+ {
212
+ "path": "toolkit/skills/ops-local-env/references/profile.example.json",
213
+ "sha256": "8ee626a751277c92a294e56e0d8417af2e186b0db937715d8e5e99f5dc399095",
214
+ "size": 4785
215
+ },
216
+ {
217
+ "path": "toolkit/skills/ops-local-env/references/PROFILE.md",
218
+ "sha256": "f72a11113aa51f20d486778d10f8a49fa3d3d5b39dc179076a380ae649445968",
219
+ "size": 4221
220
+ },
221
+ {
222
+ "path": "toolkit/skills/ops-local-env/scripts/admin_creds.py",
223
+ "sha256": "f08e4ef32d9fa6427eeab7612bbe31dce562955d541c21bdba8324c92631bddd",
224
+ "size": 9675
225
+ },
226
+ {
227
+ "path": "toolkit/skills/ops-local-env/scripts/cilium_heal.py",
228
+ "sha256": "88ebb9670b86fff9674d3e9f212bd3ff78dea68f563a4b85ab0dc329320e40a0",
229
+ "size": 6123
230
+ },
231
+ {
232
+ "path": "toolkit/skills/ops-local-env/scripts/ensure_repos.py",
233
+ "sha256": "4835f57b36f6189bcfad8543891f47f64a240e91da47340dff97d91e083ba462",
234
+ "size": 3081
235
+ },
236
+ {
237
+ "path": "toolkit/skills/ops-local-env/scripts/envprofile.py",
238
+ "sha256": "32956950c7c22f3f98ccde0fafc71abb2d29208dbaaed9347f3727cd4124cd41",
239
+ "size": 5881
240
+ },
241
+ {
242
+ "path": "toolkit/skills/ops-local-env/scripts/explain_config.py",
243
+ "sha256": "204613e7c1fb50ae82eac8ffcc09e4eeb3a9979003bd0b205ba804fbe022af1a",
244
+ "size": 3774
245
+ },
246
+ {
247
+ "path": "toolkit/skills/ops-local-env/scripts/health.py",
248
+ "sha256": "bdbebb97822cdb46f3fa3d3ade7d30c32521e96fbcbe00b0d9df524519bfca3f",
249
+ "size": 5321
250
+ },
251
+ {
252
+ "path": "toolkit/skills/ops-local-env/scripts/hosts_entry.py",
253
+ "sha256": "be2e8ad08a6fe3adb2178b30f49c89049b661c1e35ea1a7949655d20e16f4479",
254
+ "size": 6426
255
+ },
256
+ {
257
+ "path": "toolkit/skills/ops-local-env/scripts/init_profile.py",
258
+ "sha256": "7fb1c2dc1962fd85a0c1c47221ce1f821bae9ba4fe6b2ba3428401022ae34bb4",
259
+ "size": 10392
260
+ },
261
+ {
262
+ "path": "toolkit/skills/ops-local-env/scripts/k3d_images.py",
263
+ "sha256": "bba51f66940f776328c5da2d70ee3aaf0c113082fa33fe72dea3f021d32df565",
264
+ "size": 2584
265
+ },
266
+ {
267
+ "path": "toolkit/skills/ops-local-env/scripts/preflight.py",
268
+ "sha256": "745b8df59c2055ff9356da2839e8a2aa544d0b7b033721b509a0ce13a2d1ae93",
269
+ "size": 3828
270
+ },
271
+ {
272
+ "path": "toolkit/skills/ops-local-env/scripts/registry_secret.py",
273
+ "sha256": "3460d046c7b9dc2aeaf93d052a603385211faf5a83b1fd05157cfd24da1507fe",
274
+ "size": 2833
275
+ },
276
+ {
277
+ "path": "toolkit/skills/ops-local-env/scripts/shared_config.py",
278
+ "sha256": "b8318bf8adec3ec85cbdcb475d6bf9704d659d383ffb839b11af5b65753ed74f",
279
+ "size": 7849
280
+ },
281
+ {
282
+ "path": "toolkit/skills/ops-local-env/scripts/stack_plan.py",
283
+ "sha256": "92e7a7f2a675852aa0b768dcc56df82a16c87a91530b9deb44e4b8dea3d99ef8",
284
+ "size": 4185
285
+ },
286
+ {
287
+ "path": "toolkit/skills/ops-local-env/scripts/teardown.py",
288
+ "sha256": "8888522a1abd66ae8a6a2924f26fc6b0bf5de78784c6cc9e6e5410e1709a6c8d",
289
+ "size": 4106
290
+ },
291
+ {
292
+ "path": "toolkit/skills/ops-local-env/scripts/test_local_env.py",
293
+ "sha256": "23a2e7d723d23a0de4d87593373036484d67cba5a3157165bfb8efcabec2d9b9",
294
+ "size": 18531
295
+ },
296
+ {
297
+ "path": "toolkit/skills/ops-local-env/scripts/trust_ca.py",
298
+ "sha256": "6ec86dfd70d61dbfb39859b1ea178ca9f06925c8082e057f5cba2655bf3a7d8e",
299
+ "size": 6911
300
+ },
301
+ {
302
+ "path": "toolkit/skills/ops-local-env/SKILL.md",
303
+ "sha256": "a3ecabd37d625d80c40dd033e2204be44858340c9c9398aa3fd2bc4896282851",
304
+ "size": 12468
305
+ },
186
306
  {
187
307
  "path": "toolkit/skills/ops-monitor/references/alert-rules.md",
188
308
  "sha256": "28be1bd1babdaa3de9fc58f859060697c31b9249cc684c9c4272a9c3bc159db9",
@@ -1,12 +1,12 @@
1
- 77d09c309061991343ef7ae42181afb7b8f9684c74a3f3a10166c93dbcec6508 toolkit/AGENTS.md
1
+ d6efcedeecf65b215528c12499ed3eb494a7343ce225b80f97473bfcbecd4ea3 toolkit/AGENTS.md
2
2
  e79e1ab404abf83a4f90838a2f6450c387ada7e65b137a18f70f0cab74fc14f0 toolkit/install.ps1
3
- 53fddfb0424676929f72d844faa319f2e4eba9252f1c2c31fd8780c9a61f224a toolkit/scripts/install-claude-skills.ps1
4
- a3451bd0978790d2bca9eecce1f2ab79e9351c3e9ef4693d8e8e3f245db0d96f toolkit/scripts/install-codex-skills.ps1
5
- 61dd1e2c41cb7e09ef4e197c38989dc72a836bc663a40ddeeb099733f01261e3 toolkit/scripts/uninstall-claude-skills.ps1
6
- 092b5633861406e0e83fc62ecb261a678237197fd500933eb7a3d5915ed826e4 toolkit/scripts/uninstall-codex-skills.ps1
3
+ cbfbbb138ee15a1faf54b9ad018baf6e4181ed5696ee4400acc2bafa8d2e9314 toolkit/scripts/install-claude-skills.ps1
4
+ b1b25a1cf7d1798aec8fc047b483bb9f83c715f4e65d6ada3119720ebc44f262 toolkit/scripts/install-codex-skills.ps1
5
+ 3ad6b2d7047b751e632f4a54d58e260b6d8a8d6ebd41f88f324b9cfbe665ecf4 toolkit/scripts/uninstall-claude-skills.ps1
6
+ dc99a6d0ec4c5f015f02280e61de913b41edc2ef0e36c77b9d7c4749359b97d1 toolkit/scripts/uninstall-codex-skills.ps1
7
7
  712382d838a18b6cc6a5285b3c536fac74138c752a3fa1fd318828b19ece6b8f toolkit/sdtk-spec.config.json
8
8
  2a306c1609499fb4910b86d5ec6e8c796e0cdf72c5f97fe3df9c1388ac62b913 toolkit/sdtk-spec.config.profiles.example.json
9
- 3ad54f730fefdc94e5107a49b3d4a64e4169b035ceae90a4830d6f48944b2177 toolkit/SDTKOPS_TOOLKIT.md
9
+ d6193777823244b3e161be6056f329b916ae97f29a6674f66f4aa2e14891bcff toolkit/SDTKOPS_TOOLKIT.md
10
10
  1cd81e12cebdb2be528803e2d8afe43959aab1493e55499af529b99ec566a56c toolkit/skills/ops-backup/references/backup-script-patterns.md
11
11
  76e8385190d967bf98b3cafbbf8925d9b9c656ee7a7ed66ff51285b6459ebff1 toolkit/skills/ops-backup/SKILL.md
12
12
  d27e47b0c832656c2835e3d3e32dae7c86419014199439b10fc6823956324716 toolkit/skills/ops-ci-cd/references/pipeline-examples.md
@@ -18,7 +18,7 @@ a0bb24484cba68a7201e6b7f614c8b5ada8b2dff540a4e4390661a0ced112e8d toolkit/skills
18
18
  d70b59d276edf5c6c8aebb5fc669b8f6d04673fc8e8561cbaf4d7e5fb9f4e2f2 toolkit/skills/ops-debug/references/root-cause-tracing.md
19
19
  d5f58322afebcf5c3a110b02de0d2eec4494f9ed9d358b113b6717275c3524af toolkit/skills/ops-debug/SKILL.md
20
20
  c2cacc94ffba4d7ef84e635c2078e08abb8d52f79afbbb1534661c0e0cf9bda6 toolkit/skills/ops-deploy/SKILL.md
21
- 6f38c9b2ab972f272fb86e17926585a9a254a1c48c8454459a61315d4bd81d81 toolkit/skills/ops-discover/SKILL.md
21
+ 389ceec83758728ada6ed3b4e9c102646084bc041b051b7d3da290a5ac55b78e toolkit/skills/ops-discover/SKILL.md
22
22
  282645df98f039cbf8b1b29f52fe74b31c83790b1452240968e10a477947a884 toolkit/skills/ops-framer-deploy/framer-deploy.config.example.json
23
23
  12e17fa0870d2d5ce5b4d736b6ab34a54cc2953f4b011c22330d781c2ac37879 toolkit/skills/ops-framer-deploy/package.json
24
24
  ff1ee39fbf002036b57b01ce110a1a40ebbe66696d5e180944079b64dd527a56 toolkit/skills/ops-framer-deploy/scripts/framer-extract.mjs
@@ -34,6 +34,30 @@ fda6d9cadc5a3757e5559798a67716a6356809735b076d47d6bd99a993b71b99 toolkit/skills
34
34
  df03ad86862020941e69b90ea1f2ccf8cd69762e53f0a539936c16fb433e61c8 toolkit/skills/ops-incident/SKILL.md
35
35
  14f02a1921cb58e2c54c355c0b24ffdf5a9bdb91a7be6921f22da5974787efee toolkit/skills/ops-infra-plan/references/iac-patterns.md
36
36
  35eec623e41603dae0a1a328c1e6d822d2e1dc79a471f06bab3c1f3e2d552e53 toolkit/skills/ops-infra-plan/SKILL.md
37
+ 639bf209d35cc8392c4beb76d9a367118a88babf570766d128d26df3ca133426 toolkit/skills/ops-local-env/references/bootstrap/cilium-values.yaml
38
+ 4fc9433ffa646d9789e1e6064eb5eb1fd71430141ae456a55a65ab278611b45c toolkit/skills/ops-local-env/references/bootstrap/k3d-cluster.yaml
39
+ 11883fcfa1d9ca28d5a5b37bbb3c7e449aac4821b298195c3d8b9df812ab3446 toolkit/skills/ops-local-env/references/CLUSTER_CA.md
40
+ 5f11aaf849bfe0cf9ad061e3711fce2c09a2317f3118ca0f8020cd1b5cfafdb0 toolkit/skills/ops-local-env/references/GOTCHAS.md
41
+ 1d92cd11ef56944b07797071daa8b3d0f945f2e9e9822794d597115f3ae28884 toolkit/skills/ops-local-env/references/K3D_CILIUM_BOOTSTRAP.md
42
+ 8ee626a751277c92a294e56e0d8417af2e186b0db937715d8e5e99f5dc399095 toolkit/skills/ops-local-env/references/profile.example.json
43
+ f72a11113aa51f20d486778d10f8a49fa3d3d5b39dc179076a380ae649445968 toolkit/skills/ops-local-env/references/PROFILE.md
44
+ f08e4ef32d9fa6427eeab7612bbe31dce562955d541c21bdba8324c92631bddd toolkit/skills/ops-local-env/scripts/admin_creds.py
45
+ 88ebb9670b86fff9674d3e9f212bd3ff78dea68f563a4b85ab0dc329320e40a0 toolkit/skills/ops-local-env/scripts/cilium_heal.py
46
+ 4835f57b36f6189bcfad8543891f47f64a240e91da47340dff97d91e083ba462 toolkit/skills/ops-local-env/scripts/ensure_repos.py
47
+ 32956950c7c22f3f98ccde0fafc71abb2d29208dbaaed9347f3727cd4124cd41 toolkit/skills/ops-local-env/scripts/envprofile.py
48
+ 204613e7c1fb50ae82eac8ffcc09e4eeb3a9979003bd0b205ba804fbe022af1a toolkit/skills/ops-local-env/scripts/explain_config.py
49
+ bdbebb97822cdb46f3fa3d3ade7d30c32521e96fbcbe00b0d9df524519bfca3f toolkit/skills/ops-local-env/scripts/health.py
50
+ be2e8ad08a6fe3adb2178b30f49c89049b661c1e35ea1a7949655d20e16f4479 toolkit/skills/ops-local-env/scripts/hosts_entry.py
51
+ 7fb1c2dc1962fd85a0c1c47221ce1f821bae9ba4fe6b2ba3428401022ae34bb4 toolkit/skills/ops-local-env/scripts/init_profile.py
52
+ bba51f66940f776328c5da2d70ee3aaf0c113082fa33fe72dea3f021d32df565 toolkit/skills/ops-local-env/scripts/k3d_images.py
53
+ 745b8df59c2055ff9356da2839e8a2aa544d0b7b033721b509a0ce13a2d1ae93 toolkit/skills/ops-local-env/scripts/preflight.py
54
+ 3460d046c7b9dc2aeaf93d052a603385211faf5a83b1fd05157cfd24da1507fe toolkit/skills/ops-local-env/scripts/registry_secret.py
55
+ b8318bf8adec3ec85cbdcb475d6bf9704d659d383ffb839b11af5b65753ed74f toolkit/skills/ops-local-env/scripts/shared_config.py
56
+ 92e7a7f2a675852aa0b768dcc56df82a16c87a91530b9deb44e4b8dea3d99ef8 toolkit/skills/ops-local-env/scripts/stack_plan.py
57
+ 8888522a1abd66ae8a6a2924f26fc6b0bf5de78784c6cc9e6e5410e1709a6c8d toolkit/skills/ops-local-env/scripts/teardown.py
58
+ 23a2e7d723d23a0de4d87593373036484d67cba5a3157165bfb8efcabec2d9b9 toolkit/skills/ops-local-env/scripts/test_local_env.py
59
+ 6ec86dfd70d61dbfb39859b1ea178ca9f06925c8082e057f5cba2655bf3a7d8e toolkit/skills/ops-local-env/scripts/trust_ca.py
60
+ a3ecabd37d625d80c40dd033e2204be44858340c9c9398aa3fd2bc4896282851 toolkit/skills/ops-local-env/SKILL.md
37
61
  28be1bd1babdaa3de9fc58f859060697c31b9249cc684c9c4272a9c3bc159db9 toolkit/skills/ops-monitor/references/alert-rules.md
38
62
  af28797b442fb94fa96dc0182881847e50b5fe9e68ecf7a71471502030f4bd27 toolkit/skills/ops-monitor/references/slo-templates.md
39
63
  2d09968790ed63dd8e0969f59023c0ced71dd182d56475689a2d3bfc3f889002 toolkit/skills/ops-monitor/SKILL.md
@@ -159,7 +159,7 @@ Use the suite products according to task intent:
159
159
  - ship code changes
160
160
  - workflow: `start -> plan -> build -> verify -> ship`
161
161
  - entry point for ambiguous slices: `code-brainstorm`
162
- - specialist engine: `code-plan`, `code-execute`, `code-tdd`, `code-debug`, `code-verify`, `code-review`, `code-ship`, `code-finish`, `code-worktree`, `code-discover`, `code-parallel` (sequential fallback when parallel dispatch is unavailable)
162
+ - specialist engine: `code-plan`, `code-execute`, `code-tdd`, `code-debug`, `code-verify`, `code-review`, `code-ship`, `code-finish`, `code-worktree`, `code-discover`, `code-ui-e2e` (desktop UI end-to-end runs), `code-parallel` (sequential fallback when parallel dispatch is unavailable)
163
163
  - `SDTK-OPS`
164
164
  - deploy or release
165
165
  - infrastructure and environment setup
@@ -167,6 +167,7 @@ Use the suite products according to task intent:
167
167
  - monitoring, incident response, security-infra, backup, compliance
168
168
  - entry: `ops-discover` (when boundary is unclear), `ops-plan`, `ops-deploy`, `ops-incident`, `ops-monitor`, `ops-backup`, `ops-verify`, `ops-debug`
169
169
  - vendor-specific: `ops-framer-deploy` when the deploy target is a Framer project
170
+ - local test environment (multi-repository stack on k3d, from its profile): `ops-local-env`
170
171
 
171
172
  Cross-cutting capabilities (not a linear lane; usable across every phase):
172
173
 
@@ -33,7 +33,7 @@ The current public package is:
33
33
  - Latest published version lookup: `npm view sdtk-ops-kit version`
34
34
 
35
35
  The truthful current operational surface after `init` is skill-driven:
36
- - the 16 `ops-*` skills remain the real operating surface
36
+ - the 17 `ops-*` skills remain the real operating surface
37
37
  - `ops-discover` remains a skill, not a CLI command
38
38
  - `ops-verify` remains the required closing skill for every canonical journey
39
39
  - `generate` remains unsupported and deferred
@@ -139,6 +139,7 @@ Other valid but non-primary routed skills in this wave:
139
139
  | `ops-container` | define secure image build and container orchestration patterns |
140
140
  | `ops-ci-cd` | build and manage pipelines, promotion flow, artifact handling, and secret controls |
141
141
  | `ops-framer-deploy` | deploy a built HTML template into a Framer project as code components |
142
+ | `ops-local-env` | set up, re-run or repair a project's local multi-repository test environment on k3d from its stack profile |
142
143
 
143
144
  ### 5.3 Operations
144
145
 
@@ -197,7 +198,8 @@ Use these documents by role:
197
198
  ## 8. Scope
198
199
 
199
200
  `SDTK-OPS` v1 contains 15 cloud-agnostic core skills, plus `ops-framer-deploy`,
200
- the one vendor-specific skill in the set (Framer Server API).
201
+ the one vendor-specific skill in the set (Framer Server API), and `ops-local-env`,
202
+ the local k3d test-environment orchestrator driven by a per-stack profile.
201
203
 
202
204
  Not part of the current supported wave:
203
205
  - provider-specific packs such as AWS, GCP, or Azure variants
@@ -16,8 +16,8 @@ if (-not (Test-Path -LiteralPath $skillsSource)) {
16
16
  }
17
17
 
18
18
  $managedSkills = @(Get-ChildItem -LiteralPath $skillsSource -Directory | Sort-Object Name)
19
- if ($managedSkills.Count -ne 16) {
20
- throw "Expected 16 managed SDTK-OPS skills but found $($managedSkills.Count)."
19
+ if ($managedSkills.Count -ne 17) {
20
+ throw "Expected 17 managed SDTK-OPS skills but found $($managedSkills.Count)."
21
21
  }
22
22
 
23
23
  if ($Scope -eq 'user') {
@@ -67,8 +67,8 @@ $installedNow = @(
67
67
  Where-Object { $managedSkills.Name -contains $_.Name } |
68
68
  Select-Object -ExpandProperty Name
69
69
  )
70
- if ($installedNow.Count -ne 16) {
71
- throw "Claude skill install incomplete. Expected 16 managed skills at $skillsDest but found $($installedNow.Count)."
70
+ if ($installedNow.Count -ne 17) {
71
+ throw "Claude skill install incomplete. Expected 17 managed skills at $skillsDest but found $($installedNow.Count)."
72
72
  }
73
73
 
74
74
  if (-not $Quiet) {
@@ -81,8 +81,8 @@ if (-not (Test-Path -LiteralPath $skillsSource)) {
81
81
  }
82
82
 
83
83
  $managedSkills = @(Get-ChildItem -LiteralPath $skillsSource -Directory | Sort-Object Name)
84
- if ($managedSkills.Count -ne 16) {
85
- throw "Expected 16 managed SDTK-OPS skills but found $($managedSkills.Count)."
84
+ if ($managedSkills.Count -ne 17) {
85
+ throw "Expected 17 managed SDTK-OPS skills but found $($managedSkills.Count)."
86
86
  }
87
87
 
88
88
  $codexHome = Resolve-CodexHome -TargetScope $Scope -TargetProjectPath $ProjectPath
@@ -132,8 +132,8 @@ $installedNow = @(
132
132
  Where-Object { $expectedNames -contains $_.Name } |
133
133
  Select-Object -ExpandProperty Name
134
134
  )
135
- if ($installedNow.Count -ne 16) {
136
- throw "Codex skill install incomplete. Expected 16 managed skills at $skillsDest but found $($installedNow.Count)."
135
+ if ($installedNow.Count -ne 17) {
136
+ throw "Codex skill install incomplete. Expected 17 managed skills at $skillsDest but found $($installedNow.Count)."
137
137
  }
138
138
 
139
139
  if (-not $Quiet) {
@@ -18,8 +18,8 @@ if (-not (Test-Path -LiteralPath $skillsSource)) {
18
18
  $managedSkillNames = @(
19
19
  Get-ChildItem -LiteralPath $skillsSource -Directory | Sort-Object Name | Select-Object -ExpandProperty Name
20
20
  )
21
- if ($managedSkillNames.Count -ne 16) {
22
- throw "Expected 16 managed SDTK-OPS skills but found $($managedSkillNames.Count)."
21
+ if ($managedSkillNames.Count -ne 17) {
22
+ throw "Expected 17 managed SDTK-OPS skills but found $($managedSkillNames.Count)."
23
23
  }
24
24
 
25
25
  if ($Scope -eq 'user') {
@@ -43,8 +43,8 @@ $managedSkillNames = @(
43
43
  Sort-Object Name |
44
44
  ForEach-Object { "sdtk-$($_.Name)" }
45
45
  )
46
- if ($managedSkillNames.Count -ne 16) {
47
- throw "Expected 16 managed SDTK-OPS skills but found $($managedSkillNames.Count)."
46
+ if ($managedSkillNames.Count -ne 17) {
47
+ throw "Expected 17 managed SDTK-OPS skills but found $($managedSkillNames.Count)."
48
48
  }
49
49
 
50
50
  $codexHome = Resolve-CodexHome -TargetScope $Scope -TargetProjectPath $ProjectPath
@@ -61,6 +61,7 @@ Use `ops-parallel` only when the work can safely split after the primary skill c
61
61
  |-------|-------------------|
62
62
  | `ops-infra-plan` | you are designing infrastructure, networking, IAM, or resource topology before provisioning |
63
63
  | `ops-deploy` | you are executing a rollout, promotion, cutover, or rollback |
64
+ | `ops-local-env` | you are setting up, re-running or repairing a project's local test environment (k3d stack from its profile) |
64
65
  | `ops-container` | you are building images, Dockerfiles, manifests, or container runtime patterns |
65
66
  | `ops-ci-cd` | you are setting up or modifying pipelines, artifact flow, or deployment gates |
66
67
 
@@ -97,6 +98,7 @@ Use `ops-parallel` only when the work can safely split after the primary skill c
97
98
  | Backup hardening | `ops-backup` -> `ops-infra-plan` -> `ops-monitor` -> `ops-verify` |
98
99
  | Cost review | `ops-cost` -> `ops-infra-plan` -> `ops-deploy` -> `ops-verify` |
99
100
  | Security hardening | `ops-security-infra` -> `ops-infra-plan` -> `ops-ci-cd` -> `ops-verify` |
101
+ | Local test environment | `ops-local-env` -> `ops-verify` |
100
102
 
101
103
  ## Red Flags
102
104
 
@@ -0,0 +1,172 @@
1
+ ---
2
+ name: ops-local-env
3
+ description: Local test environment for a multi-repository stack on Kubernetes (k3d). Use when setting up, re-running or repairing a project's local cluster end to end -- confirming tools, registry token, repositories, shared config values and one admin login, then bootstrapping the cluster and its local CA and installing every component in order through each repository's own installer, hosts file and CA trust included -- or when changing a shared domain / namespace across all repositories.
4
+ ---
5
+
6
+ # Ops Local Env
7
+
8
+ A test environment is a stack: several repositories cloned side by side in one workspace, each with
9
+ its own config file and installer, one local cluster, one local CA. Everything particular to a stack —
10
+ repositories, config files, shared keys, admin login, host names, CA, install order, health checks —
11
+ lives in its profile, `ops-env.profile.json` in the anchor repository (`references/PROFILE.md`,
12
+ `references/profile.example.json`). The skill and its scripts hold no stack names. Paths below
13
+ (`scripts/`, `references/`) are relative to this skill's folder; run the scripts with `python3`.
14
+
15
+ ## Critical Constraints
16
+
17
+ 1. **Nothing in a config file or in the cluster changes before step 0 is confirmed** (the Apply
18
+ summary gets a yes). Before that, only installing the missing Python packages / tools the person
19
+ agrees to, and cloning missing repositories after a yes.
20
+ 2. **Never tear down** — no cluster delete, namespace / PVC deletion, `--reset`, destroy script —
21
+ except the reset of a **local k3d cluster** the person picked (step 0.5, or a teardown they asked
22
+ for), always through `scripts/teardown.py --apply --confirm <name>` after one more confirmation naming
23
+ the cluster. Never offer a reset of a non-k3d context.
24
+ 3. **Confirm the kube context** (`kubectl config current-context`) at the start and before every
25
+ component that changes the cluster.
26
+ 4. **Secrets stay out of sight.** Never ask for a registry token in chat, echo it or put it on a
27
+ command line — it lives in the environment variable the profile names. Never print a password or
28
+ a private key; the shared admin password is printed once, in the final summary, by
29
+ `admin_creds.py --reveal`. A typed password goes in through `--password-stdin` from a quoted
30
+ heredoc, never as an argument. Passwords live only in gitignored secrets files: never stage them
31
+ and never `git diff` / `git show` / `git log -p` a password file the script reports as tracked.
32
+ 5. **Each component's own installer and its rules win.** Run the repository's own skill or command;
33
+ keep its gates (config confirmation, deploy go-ahead). Settled values (context, shared values,
34
+ admin login) count as already stated, so its interview covers only its own keys.
35
+ 6. **Elevated commands go to the person.** Hosts file and trust store need root / Administrator: the
36
+ scripts print the exact command; hand it over, wait, re-check. Never run `sudo` yourself.
37
+ 7. **Config files are edited line by line by the scripts** (value only, comment kept, read back),
38
+ never rewritten with a YAML dumper, never by hand when a script covers the key.
39
+ 8. **Do not commit or push** anything unless the person asks.
40
+
41
+ ## Process
42
+
43
+ The person's request picks the mode: **install / re-run** (steps 0–4), **health** ("is it still up?":
44
+ `scripts/health.py`, read-only, nothing to confirm), **teardown** (section below), or **new profile**.
45
+
46
+ **No profile yet:** `scripts/init_profile.py --root <workspace>` drafts one from the cloned repositories
47
+ (read-only). Go through its `_todo` list with the person, fix the draft, `--write` it into the anchor
48
+ repository, remove `_todo`, and `scripts/stack_plan.py --check` must pass before step 0.
49
+
50
+ 0. **Confirm before anything** (below): admin login → tools / Python / token → repositories → core
51
+ values → existing clusters → extra changes → Apply summary.
52
+ 1. **Cluster and CA** — the profile's first component (bootstrap), then its health checks.
53
+ 2. **Components** in profile order, each through its own installer, health-checked; the CA loaded as
54
+ ClusterIssuer right after the component that installs cert-manager; the registry pull secret
55
+ before the first component that needs it; admin Secrets once their namespace exists.
56
+ 3. **Ingresses, hosts file, CA trust**, then names resolve and answer.
57
+ 4. **Final summary** — one table, plus the admin login printed once.
58
+
59
+ Once the Apply summary is confirmed the run goes **end to end without asking between components**.
60
+ It stops only at a component's own gate and on a failure (then: retry / skip this component / stop).
61
+
62
+ ## 0. Confirm before anything
63
+
64
+ Ask one decision at a time or a few at once (at most 4 per round), with the current value first as
65
+ `Keep <value> (current)`. Use the runtime's question tool when it has one.
66
+
67
+ - **0.0 Admin login first.** `scripts/admin_creds.py --show` (standard library, runs before any
68
+ install): users per file, passwords as `set` / `EMPTY`. Ask: user (keep / new, `^[a-z][a-z0-9_-]{2,31}$`)
69
+ and password (keep — only when all are set and equal / generate / type my own). "Type my own": say it
70
+ will stay in the conversation transcript, ask for it in a plain message, check 12–64 characters,
71
+ no space and none of `"` `'` `` ` `` `\` `$`; never repeat it. A password once in a tracked file
72
+ (`tracked by git`) should not be kept: recommend generate.
73
+ - **0.1 Tools and Python.** `scripts/preflight.py`. `tools MISSING`: name them and stop. `python3
74
+ MISSING`: ask, then `python3 -m pip install --user <packages>` (`--break-system-packages` only after
75
+ asking again when pip refuses with `externally-managed-environment`). Re-run until OK.
76
+ - **0.2 Registry token.** `<TOKEN> MISSING / WRONG`: ask the person to export it in their own shell
77
+ profile and restart the agent session from that shell (for GitHub: a **classic** PAT with the
78
+ profile's scope; fine-grained PATs get 403). Re-run preflight; show the `OK` line (owner, scopes).
79
+ - **0.3 Repositories.** `scripts/ensure_repos.py [--https]`: clones what is missing, never pulls.
80
+ `FAILED` / `BLOCKED`: stop. Behind with no local changes: ask whether to `git pull --ff-only`. Local
81
+ changes or not on the default branch: report, do not touch, ask whether to go on as is. Then
82
+ `scripts/stack_plan.py --check` (profile problems stop the run) and `scripts/shared_config.py --show`.
83
+ - **0.4 Core values** (`core_keys` of the profile). `scripts/explain_config.py <primary config>`
84
+ first, then ask them in one round. Do not ask for other domains: every `*_domain` is one label
85
+ under the base domain and follows it.
86
+ - **0.5 Existing clusters.** `kubectl config get-contexts`, `k3d cluster list`: one table (context,
87
+ cluster, current, local k3d or not). For each local k3d cluster ask `Keep` / `Reset` — say a reset
88
+ deletes everything in it; record, delete nothing yet. For each kept one run the profile's
89
+ `cluster.heal` script with `--check` (none: `scripts/cilium_heal.py --cluster <name> --check`) and
90
+ report what step 1 will heal. Other contexts: list only.
91
+ Ask the scenario: everything, or which components (the bootstrap, the CA issuer, hosts and trust run
92
+ anyway; a CA re-issue forces every component).
93
+ - **0.6 Anything else?** Ingresses to enable, a domain's first label, TLS subject — only what the
94
+ person names.
95
+ - **Apply.** One summary table: every shared value old → new, every `*_domain` that follows a new
96
+ base domain, admin user old → new and password keep / generate, kube context, clusters to **reset**
97
+ (bold), components to install, Ingresses. Say that a yes starts the whole run and that a change of a
98
+ value in the certificate's SAN list (base domain, namespace, database name) means a new CA
99
+ (`references/CLUSTER_CA.md`). On yes:
100
+ `shared_config.py --set K=V ...` (dry run, show diff) then `--apply`;
101
+ `admin_creds.py [--user N] [--generate | --password-stdin]` (dry run, masked) then `--apply`;
102
+ re-run both `--show`: no `MISMATCH`, users and passwords `all the same`.
103
+
104
+ ## 1–2. Cluster, components, CA
105
+
106
+ For each component of `scripts/stack_plan.py` in order:
107
+
108
+ 1. Work from its repository. Show `scripts/explain_config.py` of its configs (secrets masked), no question.
109
+ Its `notes` in the profile are rules of this stack: apply them to its run (they win over its defaults).
110
+ 2. Reset (only the one confirmed in 0.5): ask once more naming the cluster, `k3d cluster delete
111
+ <name>`, check it is gone. Kept cluster: heal it first (profile `cluster.heal`, else `scripts/cilium_heal.py --cluster <name>`;
112
+ it must end healthy). A stack without a bootstrap yet: `references/K3D_CILIUM_BOOTSTRAP.md`.
113
+ 3. Run it: its skill (invoke it if listed; else read `<repo>/.claude/skills/<skill>/SKILL.md` or
114
+ `<repo>/.codex/skills/...` in full and follow it), or its `run` command. A `long` one runs in the
115
+ background with a log file and is checked when it exits.
116
+ 4. Health: its `health` commands (`{key}` filled from the primary config). Healthy: one line, go on.
117
+ Not healthy: diagnose with that component's troubleshooting and `references/GOTCHAS.md`, then ask
118
+ retry / skip / stop.
119
+
120
+ At the right moments, without a question (part of the confirmed run):
121
+ - after the component named in `ca.issuer_after`: load the CA as `ca.cluster_issuer`
122
+ (`references/CLUSTER_CA.md`; a **different** root already in the cluster: ask before rotating);
123
+ - before the first component with `needs_registry_secret`: `scripts/registry_secret.py <namespace>`;
124
+ - once the apps namespace exists: `scripts/admin_creds.py --k8s-secrets <namespace>` when the profile
125
+ lists `admin.k8s_secrets`;
126
+ - locally built images: `scripts/k3d_images.py --cluster <name> <image> ...` before the component
127
+ that runs them.
128
+
129
+ ## 3. Ingresses, hosts, trust
130
+
131
+ 1. Render (`ingress.render`), check every host / namespace / `secretName` against the agreed values
132
+ (wrong: fix the config, never the rendered file), `kubectl diff -f <dir>`, apply, diff again = 0.
133
+ One TLS Secret per host; no two Ingresses on the same host and path; Envoy rejected count 0.
134
+ 2. `scripts/hosts_entry.py --show`; not up to date: hand over the command it prints, wait, re-check.
135
+ 3. `scripts/trust_ca.py --show`; not trusted: hand over the command; `name constraints: NONE`: back to
136
+ the re-issue. A re-issued CA leaves the old one in the store: hand over its removal.
137
+ 4. Every name resolves to the profile's IP and answers over HTTPS (`curl -s -o /dev/null -w
138
+ '%{http_code}'`); an Ingress not applied is reported as such, not as a failure.
139
+
140
+ ## 4. Final summary
141
+
142
+ One table: component, namespace, status, URL, anything left for the person. Then the admin login,
143
+ once: `scripts/admin_creds.py --reveal` (refuses when they differ — show `--show` instead); say which
144
+ UIs use it and that it is now in the transcript. Services with no Ingress: give the `kubectl
145
+ port-forward` command.
146
+
147
+ ## Health, any time
148
+
149
+ `scripts/health.py [--only <id> ...]` runs every component's `health` commands (filled from the
150
+ primary config) and prints one OK / FAIL table. It runs only read-only commands and reports a changing
151
+ one as REFUSED. After a reboot, a FAIL on every network check with Running pods: heal the cluster
152
+ (`cluster.heal`, `references/GOTCHAS.md`), then run it again.
153
+
154
+ ## Teardown (only when the person asks for it)
155
+
156
+ 1. `scripts/teardown.py` — plan only: the k3d cluster the profile names, its nodes, and what stays
157
+ (repositories, config and secrets, the local CA, other clusters and contexts).
158
+ 2. Show it and ask, naming the cluster — everything in it is lost (databases, buckets, queues).
159
+ 3. `scripts/teardown.py --apply --confirm <name>`; it checks the cluster is gone.
160
+ 4. Hand over the hosts-block removal it prints (`hosts_entry.py --remove`, elevated). Keep the CA
161
+ trusted unless the person also wants that gone.
162
+
163
+ ## Common mistakes
164
+
165
+ | Mistake | Instead |
166
+ |---|---|
167
+ | Asking "continue?" after every healthy component | Go straight on; stop only at gates and failures |
168
+ | Re-asking the admin password inside a component's installer | Hand over the settled login; it counts as stated |
169
+ | Editing a rendered file to fix a host | Fix the config value, re-render |
170
+ | Deleting a cluster or volume to "start clean" | Only the reset confirmed in step 0.5 |
171
+ | Running `sudo` from the agent shell | Hand the printed command to the person |
172
+ | Recreating a Secret that holds state (vault / encryption key) | Never; missing with data present: stop and ask |