feat: Add MergeTrain options#285
Conversation
ca008e4 to
db9ffe6
Compare
Signed-off-by: Cyrill Näf <cyrill.naef@gmail.com>
db9ffe6 to
935bf0c
Compare
|
@BigGold1310 is this ready for review? |
|
@BigGold1310 I would love to merge this, is this fine for you? |
|
@henrysachs Ready for review. |
There was a problem hiding this comment.
Thanks for the PR @BigGold1310 — this looks very close.
I may be missing something, but I think there are still two controller-side gaps:
-
isProjectUpToDate()inpkg/namespaced/controller/projects/projects/project.go(and the generated mirror inpkg/cluster/controller/projects/projects/zz_project.go) still does not comparemergeTrainsEnabled,mergeTrainsSkipTrainAllowed, ormergePipelinesEnabled.
That means a spec change limited to these fields would still be treated as up to date, soEditProjectwould never be called for that change. -
lateInitialize()in the same controller files does not seem to backfill these new fields intospec.forProviderwhen they are unset.
So adopted/imported resources, or projects relying on GitLab defaults, would not get these values initialized the same way as nearby optional project settings.
The API / CRD / client wiring looks good to me — it just seems the reconcile path is not fully wired for the new fields yet.
Description of your changes
Add support for
MergeTrainsEnabled,MergeTrainsSkipTrainAllowed, andMergePipelinesEnabledfields to the GitLab Project resource.I have:
make reviewable testto ensure this PR is ready for review.How has this code been tested