-
Story
-
Resolution: Done
-
Major
-
None
-
Strategic Portfolio Work
-
False
-
None
-
False
-
OCPSTRAT-598 - Initial Dev Preview version of MicroShift
-
Workloads - 4.12, Workloads Sprint 225, Workloads Sprint 226, Workloads Sprint 227
- nested locking logic (add new lock for route controllers today)
- backport nested locking logic to 4.11
- create route-controller-manager with a minimal subset of exactly what needs to move. keep history as I did before.
- update operator (ideally ingress, but for expediency probably openshift-controller-manager) to install route-controller-manager
- hard to move to ingress operator since it is not build on openshift/library-go but on Operator SDK
- delete route controllers from openshift-controller-manager: in 4.12 a new repo will be created (route-controller-manager) for the ingress and ingress-ip controllers. This will be managed by OCMO
API side:
- admission of Route is going to be moved as an admission plugin to kube-apiserver as a carry in o/k
- API will still be served by openshift-apiserver
- Route CRD will be created in microshift project and then eventually moved to openshift/api where it will be generated from the type. It will be then consumed by microshift
Leases timeline:
in 4.11.0 we have
- route-controllers run here behind lease/openshift-controller-manager
in 4.11.z I think we need
- route-controllers run here behind lease/openshift-controller-manager AND lease/route-controller-manager. This needed so that when upgrading to 4.11.z, we do not end up with a 4.11.0 route-controllers running AND a 4.11.z route-controllers running. The PR as it currently stands would allow the two to run alongside each other
in 4.12, I think we need
- openshift-controller-manager runs behind lease/openshift-controller-manager
- route-controller-manager runs behind lease/route-controller-manager
- Create the command you want. In this case it would be `route-controller`
- Start separating the new command into dedicated directories, this let’s you later delete all the old content you don’t need.
- while moving a code into a separate repo, some dependency moved into library-go
- Complete copy of a repo (cp recursive workspaces/openshift-controller-manager/src/github.com/openshift//openshift-controller-manager, workspaces/route-controller-manager/src/github.com/openshift//openshift-controller-manager) and delete all things no longer needed while making sure the command still builds
- To verify this was done correctly, we diff everything under github.com/openshift/openshift-controller-manager/pkg/route, pkg/cmd/controller/route, and cmd/route-controller-manager and expect a zero-diff on the packages remaining
- Then run filter branch command, this fixes the git history, so we can keep it.
- David used these: https://gist.github.com/deads2k/49475a1d3c45ed7f4d7fdab73fd7f372 Filip says something new exists now and might be better: https://github.com/newren/git-filter-repo/ (look if it supports our use case)
- then sequence of commands (running like for 26 hours over origin)
- Create repo openshift/route-controller-manager – (this can be done now)
- Use the resulting repo as the starting repo and push into the new github repo
- For this, you probably need to send deads a zip of the repo
- At this point, we have a route-controller-manager with code that does not build, because all the code thinks it is in github.com/openshift/openshift-controller-manager, but it needs to be in openshift/route-controller-manager
- Now open a PR to openshift/route-controller-manager to rename package to be under github.com/openshift/route-controller-manager
- At this point we should build and you need to get images created for this new repo. There will be ART steps and test platform steps. Call the image openshift-route-controller-manager
- Get all the correct test jobs wired: Verify, Image, Parallel, Serial, Upgrade
- Now switch the deployment created in the steps below to use the new image.
- Update microshift to depend on the route-controller-manager repo and remove the openshift-controller-manager dependency
- Now delete the route-controller-manager packages from openshift-controller-manager repo
- Now you can refactor and fix whatever debt you have incurred. Jan will say how long you can spend polishing.
In parallel, after step 1
- Open a cluster-openshift-controller-manager-operator PR that adds management for a new route-controller-manager deployment.
- This will allow you to practice running as a separate binary
- Don’t merge until the picks are in 4.11.1
- Remove the part where openshift-controller-manager starts the route-controllers, this part: https://github.com/openshift/openshift-controller-manager/blob/1e9af455d1594c5b9831eec5814475345e75b1a1/pkg/cmd/openshift-controller-manager/controller_manager.go#L157-L162
- blocks
-
OCPBUGS-535 OCM operator should manager route controllers in separate ns
- Closed
-
API-1428 Split the route controllers out from OCM
- Closed
- is related to
-
API-1433 Complete Route API compatibility
- Closed
- links to