Commit a84fb3e
authored
feat: Add category mappings support to Konnector Agent Helm chart (#1385)
**What problem does this PR solve?**:
This PR adds support for extracting and passing `categoryMappings` to
the Konnector Agent Helm chart. The category mappings are derived from
`additionalCategories` specified in the worker node configuration and
controlplane configuration
Changes:
1. **Category Extraction Logic**
(`pkg/handlers/lifecycle/konnectoragent/handler.go`):
- Added `extractCategoryMappings()` function that:
- Extracts `additionalCategories` from cluster-level worker config
variables and controlplane config variables
2. **Helm Values Template**
(`charts/cluster-api-runtime-extensions-nutanix/addons/konnector-agent/values-template.yaml`):
- Added conditional rendering of `categoryMappings` field
**Which issue(s) this PR fixes**:
[Fixes #](https://jira.nutanix.com/browse/NCN-110842)
**How Has This Been Tested?**:
Created clusters using dev caren and verified the categories and
configmaps related to konnector agent
Konnector Agent HCP with category Mapping:
<img width="1089" height="878" alt="Screenshot 2025-11-12 at 8 37 19 PM"
src="https://github.com/user-attachments/assets/f2560fbb-b6b4-4555-95c8-49683d7e0c2a"
/>
Konnector Agent HCP without category mappings:
<img width="1100" height="887" alt="Screenshot 2025-11-12 at 8 37 39 PM"
src="https://github.com/user-attachments/assets/f323bf38-9175-4dd9-ab6c-a285cadf502c"
/>
**Special notes for your reviewer**:
<!--
Use this to provide any additional information to the reviewers.
This may include:
- Best way to review the PR.
- Where the author wants the most review attention on.
- etc.
-->1 parent f2f787a commit a84fb3e
File tree
4 files changed
+749
-0
lines changed- charts/cluster-api-runtime-extensions-nutanix/addons/konnector-agent
- hack/tools/fetch-images
- pkg/handlers/lifecycle/konnectoragent
4 files changed
+749
-0
lines changedLines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
382 | 382 | | |
383 | 383 | | |
384 | 384 | | |
| 385 | + | |
385 | 386 | | |
386 | 387 | | |
387 | 388 | | |
388 | 389 | | |
389 | 390 | | |
390 | 391 | | |
| 392 | + | |
391 | 393 | | |
392 | 394 | | |
393 | 395 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
23 | 24 | | |
| 25 | + | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
| |||
287 | 289 | | |
288 | 290 | | |
289 | 291 | | |
| 292 | + | |
290 | 293 | | |
291 | 294 | | |
292 | 295 | | |
| |||
301 | 304 | | |
302 | 305 | | |
303 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
304 | 310 | | |
305 | 311 | | |
306 | 312 | | |
| |||
309 | 315 | | |
310 | 316 | | |
311 | 317 | | |
| 318 | + | |
312 | 319 | | |
313 | 320 | | |
314 | 321 | | |
| |||
321 | 328 | | |
322 | 329 | | |
323 | 330 | | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
324 | 428 | | |
325 | 429 | | |
326 | 430 | | |
| |||
0 commit comments