Skip to content

render_controller: render on template MCs changes - #640

Merged
openshift-merge-robot merged 1 commit into
openshift:masterfrom
runcom:render-everything
Apr 17, 2019
Merged

openshift-merge-robot merged 1 commit into
openshift:masterfrom
runcom:render-everything

Conversation

@runcom

@runcom runcom commented Apr 17, 2019 •

Copy link
Copy Markdown
Member

I was working on triggering a resync when the pull-secret change and I
got to this:

  • pull-secret changes
  • template_controller runs and update 00- with the new pull-secret
  • stop, the new pull secret is now just in 00- MCs and not on
    nodes since there's no rendered MC which contains it

Now, the above isn't quite right since after an admin updates the
pull-secret, it must be rolled out to nodes to be able to pull images
(for e.g. an upgrade).
What's happening is that the template_controller sets an OwnerReference
of Kind: ControllerConfig, whether the render_controller only reacts to
a Kind: MachineConfigPool (and MCs that aren't controller at all, like
the template_controller tho).

This patch fixes the controller checks and we now enqueue an MCP for the
given MC if we have a pool anyway.

Signed-off-by: Antonio Murdaca [email protected]

@openshift-ci-robot openshift-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Apr 17, 2019
@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 17, 2019
@runcom

runcom commented Apr 17, 2019

Copy link
Copy Markdown
Member Author

/hold

I'm syncing with Abhinav on this, related to #632

@openshift-ci-robot openshift-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 17, 2019
@runcom
runcom force-pushed the render-everything branch from 9719b56 to 2e0e53b Compare April 17, 2019 16:31
@runcom

runcom commented Apr 17, 2019

Copy link
Copy Markdown
Member Author

Synced with Abhinav, this is now ready to go and I've added a failing test to avoid regression.

I was working on triggering a resync when the pull-secret change and I
got to this:

- pull-secret changes
- template_controller runs and update 00-<role> with the new pull-secret
- stop, the new pull secret is now just in 00-<role> MCs and not on
nodes since there's no rendered MC which contains it

Now, the above isn't quite right since after an admin updates the
pull-secret, it must be rolled out to nodes to be able to pull images
(for e.g. an upgrade).
What's happening is that the template_controller sets an OwnerReference
of Kind: ControllerConfig, whether the render_controller only reacts to
a Kind: MachineConfigPool (and MCs that aren't controller at all, like
the template_controller tho).

This patch fixes the controller checks and we now enqueue an MCP for the
given MC if we have a pool anyway.

Signed-off-by: Antonio Murdaca <[email protected]>
@runcom
runcom force-pushed the render-everything branch from 2e0e53b to 961aaf4 Compare April 17, 2019 16:33
@runcom

runcom commented Apr 17, 2019

Copy link
Copy Markdown
Member Author

/hold cancel

@openshift-ci-robot openshift-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 17, 2019
@kikisdeliveryservice

Copy link
Copy Markdown
Contributor

just waiting until it goes green to lgtm

@runcom

runcom commented Apr 17, 2019

Copy link
Copy Markdown
Member Author

just waiting until it goes green to lgtm

I think it avoids a round-trip if you put it now anyway (assuming it lgt(y)). The PR won't be merged anyway if the tests aren't green.

@kikisdeliveryservice

Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Apr 17, 2019
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kikisdeliveryservice, runcom

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [kikisdeliveryservice,runcom]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot
openshift-merge-robot merged commit 482f2a8 into openshift:master Apr 17, 2019
@runcom
runcom deleted the render-everything branch April 17, 2019 18:01
ptalgulk01 pushed a commit to ptalgulk01/machine-config-operator that referenced this pull request May 15, 2026
render_controller: render on template MCs changes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants