Skip to content

Conversation

@abhijith-darshan
Copy link
Contributor

@abhijith-darshan abhijith-darshan commented Oct 17, 2025

Description

Catalog can resolve resources from multiple sources
(Currently targeting multiple GitHub sources)

internally Catalog utilizes, flux AritfactGenerator to generate ExternalArtifact, which is consumed by Kustomization

What type of PR is this? (check all applicable)

  • 🍕 Feature
  • 🐛 Bug Fix
  • 📝 Documentation Update
  • 🎨 Style
  • 🧑‍💻 Code Refactor
  • 🔥 Performance Improvements
  • ✅ Test
  • 🤖 Build
  • 🔁 CI
  • 📦 Chore (Release)
  • ⏩ Revert

Related Tickets & Documents

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help
  • Separate ticket for tests # (issue/pr)

Test to confirm ArtifactGenerator and ExternalArtifact applies (Cluster)PluginDefinitions

Added to documentation?

  • 📜 README.md
  • 🤝 Documentation pages updated
  • 🙅 no documentation needed
  • (if applicable) generated OpenAPI docs for CRD changes

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • New and existing unit tests pass locally with my changes

@abhijith-darshan abhijith-darshan changed the title feat(catalogs): catalog resources via artifact generator feat(catalogs): multi-source catalog Oct 22, 2025
@abhijith-darshan abhijith-darshan self-assigned this Oct 22, 2025
@abhijith-darshan abhijith-darshan marked this pull request as ready for review October 22, 2025 23:37
@abhijith-darshan abhijith-darshan requested a review from a team as a code owner October 22, 2025 23:37
@abhijith-darshan abhijith-darshan force-pushed the feat/catalog_sources branch 2 times, most recently from de0214d to 4611e21 Compare October 23, 2025 00:13
Copy link
Contributor

@IvoGoman IvoGoman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good stuff. Still need to go through the controller code. Most of the comments are doc related or smaller things.

@abhijith-darshan abhijith-darshan force-pushed the feat/catalog_sources branch 3 times, most recently from 3a7d644 to 7a640c8 Compare October 23, 2025 13:10
IvoGoman
IvoGoman previously approved these changes Oct 27, 2025
updates catalog API (Breaking change)

Signed-off-by: abhijith-darshan <[email protected]>

(chore): register artifact generator scheme

Signed-off-by: abhijith-darshan <[email protected]>

(chore): removes kustomize WithPath option

Signed-off-by: abhijith-darshan <[email protected]>

(chore): adds involved object creation files

Signed-off-by: abhijith-darshan <[email protected]>

(chore): updates catalog controller

removes secret watch and secret managed label
adds custom predicate to ignore reconciliation if status hasn't changed
sets conditions for involved objects

Signed-off-by: abhijith-darshan <[email protected]>

(chore): updates env tests

Signed-off-by: abhijith-darshan <[email protected]>

(chore): updates e2e tests

Signed-off-by: abhijith-darshan <[email protected]>

(chore): updates local env flux setup

installs source-watcher for artifact generator extension
adds feature gates to enable ExternalArtifact on kustomize controller

Signed-off-by: abhijith-darshan <[email protected]>

(chore): adds helper func

Signed-off-by: abhijith-darshan <[email protected]>

(chore): adds ignore status update predicate

generic ignore status predicate for flux and greenhouse objects

Signed-off-by: abhijith-darshan <[email protected]>

(chore): array of sources in catalog spec

Signed-off-by: abhijith-darshan <[email protected]>

(chore): generate manifests

Signed-off-by: abhijith-darshan <[email protected]>

(chore): adds label keys for catalog

Signed-off-by: abhijith-darshan <[email protected]>

(chore): adds source generator for Catalog

Signed-off-by: abhijith-darshan <[email protected]>

(chore): update controller to handle multiple sources

create multiple internal catalog resources to resolve greenhouse objects from Git repo

handles deletion of orphaned internal catalog resources

Signed-off-by: abhijith-darshan <[email protected]>

(chore): updates tests

Signed-off-by: abhijith-darshan <[email protected]>

(chore): tidy up

Signed-off-by: abhijith-darshan <[email protected]>

(chore): update sample with multi-source

Signed-off-by: abhijith-darshan <[email protected]>

Automatic generation of CRD API Docs

(chore): remove scoped test

Signed-off-by: abhijith-darshan <[email protected]>

(chore): use hash/fnv instead of crypto/md5

Signed-off-by: abhijith-darshan <[email protected]>

Automatic generation of CRD API Docs

(chore): fix lint err

Signed-off-by: abhijith-darshan <[email protected]>

(chore): use strconv FormatUint instead of fmt.Sprintf

Signed-off-by: abhijith-darshan <[email protected]>

(chore): return on err

Signed-off-by: abhijith-darshan <[email protected]>

(chore): update test

Signed-off-by: abhijith-darshan <[email protected]>

(chore): err checks in unit tests

Signed-off-by: abhijith-darshan <[email protected]>

(chore): use net/url

Signed-off-by: abhijith-darshan <[email protected]>

(chore): apply code suggestions from review

Co-authored-by: IvoGoman <[email protected]>

(chore): add api docs

Signed-off-by: abhijith-darshan <[email protected]>

(chore): remove common labels

Signed-off-by: abhijith-darshan <[email protected]>

(chore): remove TODO

Signed-off-by: abhijith-darshan <[email protected]>

(chore): regenerate manifests

Signed-off-by: abhijith-darshan <[email protected]>

Automatic generation of CRD API Docs

(chore): refactor status inventory

sourceErr type to return source object errors used to set inventory errors

Signed-off-by: abhijith-darshan <[email protected]>

(chore): removes lifecycle.predicates

Signed-off-by: abhijith-darshan <[email protected]>

(chore): incrementally remove items from inventory[hash]

during orphaned resource deletion, incrementally remove items in hash to reflect the status in case of error deleting orphaned resources.

Signed-off-by: abhijith-darshan <[email protected]>

(chore): generate api docs

Signed-off-by: abhijith-darshan <[email protected]>

(chore): fix lint errs and remove status.inventory[hash] entries if len of items of hash is empty

Signed-off-by: abhijith-darshan <[email protected]>
@abhijith-darshan abhijith-darshan merged commit c98e4b5 into main Oct 27, 2025
23 checks passed
@abhijith-darshan abhijith-darshan deleted the feat/catalog_sources branch October 27, 2025 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] - Catalog Spec allows to specify PluginDefinitions

3 participants