-
Notifications
You must be signed in to change notification settings - Fork 462
Render baremetal bootstrap configs #1002
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
pkg/operator/bootstrap.go
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there some way for this to take in platform as a variable:
/manifests/{platform}/*
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/manifests/spec.Platform/*
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe, although because of the way the manifests are compiled in as bindata I'm not sure it's as simple as globbing a path. For the moment I'm just conditionalizing the list based on platform (in a commit I haven't pushed yet).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SHouldn't all these be out of this PR and just in #795 Is this just to make it work and we'll rebase as soon as 795 is merged?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Basically yes. I needed some of the changes in 795 in order to do this so I based my changes on it. We'll need to rebase this once 795 merges.
d608d42 to
f93e929
Compare
|
This is rebased now that #795 has merged. It also includes a couple of fixes for things we identified in testing. Also note that this is a dependency for openshift/installer#2067 |
| filename: "baremetal/manifests/keepalived.yaml", | ||
| }, { | ||
| name: "manifests/baremetal/keepalived.conf.tmpl", | ||
| filename: "baremetal/static-pod-resources/keepalived/keepalived.conf.tmpl", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't all these end up under bootstrap/ similar to https://github.com/openshift/machine-config-operator/pull/1002/files#diff-d6f38878757202a810cfa8038e7ae122R161
Have you tested this out manually to verify this is applied at bootstrap?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe @celebdor made this change because having them in bootstrap caused them to be applied twice - once by kubelet and again during cluster-bootstrap. We will be explicitly copying them into place in the installer[0], so the specific location here doesn't matter much.
|
cc @abhinavdahiya - can you take a look at the overall mechanism here? I feel like this is sane to do but maybe you have more insight from the installer and this can be achieved from the installer as well (key thing here is that we want the images from the payload to be available to render these manifests and previously we only had systemd units in the installer bootstrap data). |
|
The other reason we wanted to move these here was so we had a consistent templating mechanism between bootstrap and master/worker nodes. When these resources lived in the installer we had to retrieve the inputs in more hacky ways. Here we can use the exact same platform status data as the master templates. |
Baremetal deployments require a couple of additional services to run on the bootstrap node. This change adds static pod manifests and the associated configuration templates to the MCO bootstrap process. Co-authored-by: Brad P. Crochet <[email protected]> Co-authored-by: Antoni Segura Puimedon <[email protected]>
|
/approve |
|
/lgtm deferring my question to @abhinavdahiya from #1002 (comment) |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cgwalters, cybertron, runcom The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
- What I did
This moves the baremetal infra bootstrap static pod configurations to MCO, which is necessary so the installer can look up the images from the release and pass them in. Previously the pod definitions were in the installer itself, which meant they were written before bootkube.sh was run and could not use the standard method to retrieve the images. This also moves all of the baremetal infra templates into the same repo and converts them to use the MCO templating just like the master versions.
- How to verify it
Remove the existing baremetal systemd services from the installer and deploy with this series of commits. Coredns and keepalived should be deployed on the bootstrap node as static pods.
- Description for the changelog
Baremetal infra static pod definitions are now deployed during the machine-config-operator bootstrap phase.