-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
*: Pass the master, worker and bootstrap ignition content to the terraform. #301
Conversation
0e274c0
to
0e1b294
Compare
@@ -68,12 +71,14 @@ func (c *ConfigGenerator) GenerateIgnConfig(clusterDir string) error { | |||
c.appendCertificateAuthority(&ignCfg, ca) | |||
c.embedAppendBlock(&ignCfg, "master", fmt.Sprintf("etcd_index=%d", i)) | |||
|
|||
if err = ignCfgToFile(ignCfg, filepath.Join(clusterDir, fmt.Sprintf(config.IgnitionPathMaster, i))); err != nil { | |||
return err | |||
masterIgn, err := json.MarshalIndent(&ignCfg, "", " ") |
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.
we shouldn't be indenting as it will be part of the terraform.tfvars
pkg/types/config/cluster.go
Outdated
IgnitionBootstrap string `json:"openshift_ignition_bootstrap,omitempty" yaml:"-"` | ||
IgnitionMasters []string `json:"openshift_ignition_master,omitempty" yaml:"-"` | ||
IgnitionWorker string `json:"openshift_ignition_worker,omitempty" yaml:"-"` | ||
IgnitionBootstrap string `json:"ignition_bootstrap,omitempty" yaml:"ignitionBootstrap"` |
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.
changed yaml:"-"
to yaml:"<something>"
; We might wanna keep it ignored.
d499821
to
f759287
Compare
Can you fix up the commit message on the one? |
d9c525d
to
adb9063
Compare
adb9063
to
f52ea3e
Compare
Previously, the installer binary generates the ignitions for master and worker nodes, and pass the filename to the terraform. However, in the new installer binary, we will instead pass the content of the ignition files to terraform.
f52ea3e
to
9b21941
Compare
This requires openshift/release#1630. |
If the "ignition_bootstrap" is non-empty in the terraform.tfvars, then use it as the content for the bootstrap ignition. This will enable the new installer binary to launch a cluster.
9b21941
to
2e340f1
Compare
/retest |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: crawford, yifan-gu The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@yifan-gu: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
(Accidentally) superseded by #289. /close |
@crawford: Closing this PR. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Previously, the installer binary generates the ignitions for master
and worker nodes, and pass the filename to the terraform.
However, in the new installer binary, we will instead pass the content
of the ignition files to terraform.
Also adds an option to use the bootstrap ignition from the tfvars file directly.