diff --git a/docs/design/resource_dep.svg b/docs/design/resource_dep.svg index e0c011bd1ed..4faf595a3bf 100644 --- a/docs/design/resource_dep.svg +++ b/docs/design/resource_dep.svg @@ -1,1129 +1,1165 @@ - - - + + G - + installconfig.InstallConfig - -installconfig.InstallConfig + +installconfig.InstallConfig Target Install Config - -Target Install Config + +Target Install Config installconfig.InstallConfig->Target Install Config - - + + - + manifests.Manifests - -manifests.Manifests + +manifests.Manifests installconfig.InstallConfig->manifests.Manifests - - + + - + manifests.Ingress - -manifests.Ingress + +manifests.Ingress installconfig.InstallConfig->manifests.Ingress - - + + + + + +manifests.DNS + +manifests.DNS + + + +installconfig.InstallConfig->manifests.DNS + + manifests.Networking - -manifests.Networking + +manifests.Networking - + installconfig.InstallConfig->manifests.Networking - - + + tls.IngressCertKey - -tls.IngressCertKey + +tls.IngressCertKey - + installconfig.InstallConfig->tls.IngressCertKey - - + + tls.MCSCertKey - -tls.MCSCertKey + +tls.MCSCertKey - + installconfig.InstallConfig->tls.MCSCertKey - - + + manifests.Openshift - -manifests.Openshift + +manifests.Openshift - + installconfig.InstallConfig->manifests.Openshift - - + + manifests.ClusterK8sIO - -manifests.ClusterK8sIO + +manifests.ClusterK8sIO - + installconfig.InstallConfig->manifests.ClusterK8sIO - - + + machines.Worker - -machines.Worker + +machines.Worker - + installconfig.InstallConfig->machines.Worker - - + + machine.Worker - -machine.Worker + +machine.Worker - + installconfig.InstallConfig->machine.Worker - - + + machines.Master - -machines.Master + +machines.Master - + installconfig.InstallConfig->machines.Master - - + + machine.Master - -machine.Master + +machine.Master - + installconfig.InstallConfig->machine.Master - - + + bootstrap.Bootstrap - -bootstrap.Bootstrap + +bootstrap.Bootstrap - + installconfig.InstallConfig->bootstrap.Bootstrap - - + + tls.APIServerCertKey - -tls.APIServerCertKey + +tls.APIServerCertKey - + installconfig.InstallConfig->tls.APIServerCertKey - - + + - + kubeconfig.Admin - -kubeconfig.Admin + +kubeconfig.Admin - + installconfig.InstallConfig->kubeconfig.Admin - - + + - + kubeconfig.Kubelet - -kubeconfig.Kubelet + +kubeconfig.Kubelet - + installconfig.InstallConfig->kubeconfig.Kubelet - - + + - + cluster.TerraformVariables - -cluster.TerraformVariables + +cluster.TerraformVariables - + installconfig.InstallConfig->cluster.TerraformVariables - - + + - + cluster.Cluster - -cluster.Cluster + +cluster.Cluster - + installconfig.InstallConfig->cluster.Cluster - - + + installconfig.clusterID - -installconfig.clusterID + +installconfig.clusterID installconfig.clusterID->installconfig.InstallConfig - - + + installconfig.sshPublicKey - -installconfig.sshPublicKey + +installconfig.sshPublicKey installconfig.sshPublicKey->installconfig.InstallConfig - - + + installconfig.baseDomain - -installconfig.baseDomain + +installconfig.baseDomain installconfig.baseDomain->installconfig.InstallConfig - - + + - + -installconfig.clusterName - -installconfig.clusterName +installconfig.platform + +installconfig.platform - + + +installconfig.platform->installconfig.InstallConfig + + + + -installconfig.clusterName->installconfig.InstallConfig - - +installconfig.platform->installconfig.baseDomain + + - + -installconfig.pullSecret - -installconfig.pullSecret +installconfig.clusterName + +installconfig.clusterName - + -installconfig.pullSecret->installconfig.InstallConfig - - +installconfig.clusterName->installconfig.InstallConfig + + - + -installconfig.platform - -installconfig.platform +installconfig.pullSecret + +installconfig.pullSecret - + -installconfig.platform->installconfig.InstallConfig - - +installconfig.pullSecret->installconfig.InstallConfig + + templates.Templates - -templates.Templates + +templates.Templates Target Manifest templates - -Target Manifest templates + +Target Manifest templates - + templates.Templates->Target Manifest templates - - + + bootkube.KubeCloudConfig - -bootkube.KubeCloudConfig + +bootkube.KubeCloudConfig - + bootkube.KubeCloudConfig->templates.Templates - - + + - + bootkube.KubeCloudConfig->manifests.Manifests - - + + bootkube.MachineConfigServerTLSSecret - -bootkube.MachineConfigServerTLSSecret + +bootkube.MachineConfigServerTLSSecret - + bootkube.MachineConfigServerTLSSecret->templates.Templates - - + + - + bootkube.MachineConfigServerTLSSecret->manifests.Manifests - - + + bootkube.OpenshiftServiceCertSignerSecret - -bootkube.OpenshiftServiceCertSignerSecret + +bootkube.OpenshiftServiceCertSignerSecret - + bootkube.OpenshiftServiceCertSignerSecret->templates.Templates - - + + - + bootkube.OpenshiftServiceCertSignerSecret->manifests.Manifests - - + + bootkube.Pull - -bootkube.Pull + +bootkube.Pull - + bootkube.Pull->templates.Templates - - + + - + bootkube.Pull->manifests.Manifests - - + + bootkube.CVOOverrides - -bootkube.CVOOverrides + +bootkube.CVOOverrides - + bootkube.CVOOverrides->templates.Templates - - + + - + bootkube.CVOOverrides->manifests.Manifests - - + + bootkube.HostEtcdServiceEndpointsKubeSystem - -bootkube.HostEtcdServiceEndpointsKubeSystem + +bootkube.HostEtcdServiceEndpointsKubeSystem - + bootkube.HostEtcdServiceEndpointsKubeSystem->templates.Templates - - + + - + bootkube.HostEtcdServiceEndpointsKubeSystem->manifests.Manifests - - + + bootkube.KubeSystemConfigmapEtcdServingCA - -bootkube.KubeSystemConfigmapEtcdServingCA + +bootkube.KubeSystemConfigmapEtcdServingCA - + bootkube.KubeSystemConfigmapEtcdServingCA->templates.Templates - - + + - + bootkube.KubeSystemConfigmapEtcdServingCA->manifests.Manifests - - + + bootkube.KubeSystemConfigmapRootCA - -bootkube.KubeSystemConfigmapRootCA + +bootkube.KubeSystemConfigmapRootCA - + bootkube.KubeSystemConfigmapRootCA->templates.Templates - - + + - + bootkube.KubeSystemConfigmapRootCA->manifests.Manifests - - + + bootkube.KubeSystemSecretEtcdClient - -bootkube.KubeSystemSecretEtcdClient + +bootkube.KubeSystemSecretEtcdClient - + bootkube.KubeSystemSecretEtcdClient->templates.Templates - - + + - + bootkube.KubeSystemSecretEtcdClient->manifests.Manifests - - - - - -bootkube.OpenshiftWebConsoleNamespace - -bootkube.OpenshiftWebConsoleNamespace - - - -bootkube.OpenshiftWebConsoleNamespace->templates.Templates - - - - - -bootkube.OpenshiftWebConsoleNamespace->manifests.Manifests - - + + - + bootkube.OpenshiftMachineConfigOperator - -bootkube.OpenshiftMachineConfigOperator + +bootkube.OpenshiftMachineConfigOperator bootkube.OpenshiftMachineConfigOperator->templates.Templates - - + + - + bootkube.OpenshiftMachineConfigOperator->manifests.Manifests - - + + - + bootkube.OpenshiftClusterAPINamespace - -bootkube.OpenshiftClusterAPINamespace + +bootkube.OpenshiftClusterAPINamespace bootkube.OpenshiftClusterAPINamespace->templates.Templates - - + + - + bootkube.OpenshiftClusterAPINamespace->manifests.Manifests - - + + - + bootkube.OpenshiftServiceCertSignerNamespace - -bootkube.OpenshiftServiceCertSignerNamespace + +bootkube.OpenshiftServiceCertSignerNamespace bootkube.OpenshiftServiceCertSignerNamespace->templates.Templates - - + + - + bootkube.OpenshiftServiceCertSignerNamespace->manifests.Manifests - - + + - + bootkube.EtcdServiceKubeSystem - -bootkube.EtcdServiceKubeSystem + +bootkube.EtcdServiceKubeSystem bootkube.EtcdServiceKubeSystem->templates.Templates - - + + - + bootkube.EtcdServiceKubeSystem->manifests.Manifests - - + + - + bootkube.HostEtcdServiceKubeSystem - -bootkube.HostEtcdServiceKubeSystem + +bootkube.HostEtcdServiceKubeSystem bootkube.HostEtcdServiceKubeSystem->templates.Templates - - + + - + bootkube.HostEtcdServiceKubeSystem->manifests.Manifests - - + + - + openshift.BindingDiscovery - -openshift.BindingDiscovery + +openshift.BindingDiscovery openshift.BindingDiscovery->templates.Templates - - + + - + openshift.BindingDiscovery->manifests.Openshift - - + + - + openshift.CloudCredsSecret - -openshift.CloudCredsSecret + +openshift.CloudCredsSecret openshift.CloudCredsSecret->templates.Templates - - + + - + openshift.CloudCredsSecret->manifests.Openshift - - + + - + openshift.KubeadminPasswordSecret - -openshift.KubeadminPasswordSecret + +openshift.KubeadminPasswordSecret openshift.KubeadminPasswordSecret->templates.Templates - - + + - + openshift.KubeadminPasswordSecret->manifests.Openshift - - + + - + openshift.RoleCloudCredsSecretReader - -openshift.RoleCloudCredsSecretReader + +openshift.RoleCloudCredsSecretReader openshift.RoleCloudCredsSecretReader->templates.Templates - - + + - + openshift.RoleCloudCredsSecretReader->manifests.Openshift - - + + - + Target Manifests - -Target Manifests + +Target Manifests manifests.Manifests->Target Manifests - - + + - + manifests.Manifests->bootstrap.Bootstrap - - + + manifests.Ingress->manifests.Manifests - - + + - + +manifests.DNS->manifests.Manifests + + + + + manifests.Networking->manifests.Manifests - - + + - + manifests.Networking->manifests.ClusterK8sIO - - + + tls.RootCA - -tls.RootCA + +tls.RootCA - + tls.RootCA->manifests.Manifests - - + + tls.EtcdCA - -tls.EtcdCA + +tls.EtcdCA - + tls.RootCA->tls.EtcdCA - - + + tls.KubeCA - -tls.KubeCA + +tls.KubeCA - + tls.RootCA->tls.KubeCA - - + + tls.ServiceServingCA - -tls.ServiceServingCA + +tls.ServiceServingCA - + tls.RootCA->tls.ServiceServingCA - - + + - + tls.RootCA->tls.MCSCertKey - - + + - + tls.RootCA->machine.Worker - - + + - + tls.RootCA->machine.Master - - + + - + tls.RootCA->bootstrap.Bootstrap - - + + tls.AggregatorCA - -tls.AggregatorCA + +tls.AggregatorCA - + tls.RootCA->tls.AggregatorCA - - + + + + + +tls.JournalCA + +tls.JournalCA + + + +tls.RootCA->tls.JournalCA + + - + tls.RootCA->kubeconfig.Admin - - + + - + tls.RootCA->kubeconfig.Kubelet - - + + - + tls.EtcdCA->manifests.Manifests - - + + tls.EtcdClientCertKey - -tls.EtcdClientCertKey + +tls.EtcdClientCertKey - + tls.EtcdCA->tls.EtcdClientCertKey - - + + - + tls.EtcdCA->bootstrap.Bootstrap - - + + - + tls.IngressCertKey->manifests.Manifests - - + + - + tls.KubeCA->manifests.Manifests - - + + - + tls.KubeCA->tls.IngressCertKey - - + + tls.KubeletCertKey - -tls.KubeletCertKey + +tls.KubeletCertKey - + tls.KubeCA->tls.KubeletCertKey - - + + - + tls.KubeCA->bootstrap.Bootstrap - - + + - + tls.KubeCA->tls.APIServerCertKey - - + + tls.AdminCertKey - -tls.AdminCertKey + +tls.AdminCertKey - + tls.KubeCA->tls.AdminCertKey - - + + - + tls.ServiceServingCA->manifests.Manifests - - + + - + tls.ServiceServingCA->bootstrap.Bootstrap - - + + - + tls.EtcdClientCertKey->manifests.Manifests - - + + - + tls.EtcdClientCertKey->bootstrap.Bootstrap - - + + - + tls.MCSCertKey->manifests.Manifests - - + + - + tls.MCSCertKey->bootstrap.Bootstrap - - + + - + tls.KubeletCertKey->manifests.Manifests - - + + - + tls.KubeletCertKey->bootstrap.Bootstrap - - + + - + tls.KubeletCertKey->kubeconfig.Kubelet - - + + - + manifests.Openshift->Target Manifests - - + + - + manifests.Openshift->bootstrap.Bootstrap - - + + - + manifests.ClusterK8sIO->manifests.Openshift - - + + - + machines.Worker->manifests.Openshift - - + + - + machine.Worker->machines.Worker - - + + Target Ignition Configs - -Target Ignition Configs + +Target Ignition Configs - + machine.Worker->Target Ignition Configs - - + + - + machines.Master->manifests.Openshift - - + + - + machine.Master->machines.Master - - + + - + machine.Master->Target Ignition Configs - - + + - + machine.Master->cluster.TerraformVariables - - + + password.KubeadminPassword - -password.KubeadminPassword + +password.KubeadminPassword - + password.KubeadminPassword->manifests.Openshift - - + + - + password.KubeadminPassword->cluster.Cluster - - + + - + bootstrap.Bootstrap->Target Ignition Configs - - + + - + bootstrap.Bootstrap->cluster.TerraformVariables - - + + - + tls.AggregatorCA->bootstrap.Bootstrap - - + + tls.APIServerProxyCertKey - -tls.APIServerProxyCertKey + +tls.APIServerProxyCertKey - + tls.AggregatorCA->tls.APIServerProxyCertKey - - + + - + tls.APIServerCertKey->bootstrap.Bootstrap - - + + - + tls.APIServerProxyCertKey->bootstrap.Bootstrap - - + + - + tls.AdminCertKey->bootstrap.Bootstrap - - + + - + tls.AdminCertKey->kubeconfig.Admin - - + + tls.ServiceAccountKeyPair - -tls.ServiceAccountKeyPair + +tls.ServiceAccountKeyPair - + tls.ServiceAccountKeyPair->bootstrap.Bootstrap - - + + + + + +tls.JournalCA->bootstrap.Bootstrap + + + + + +tls.JournalCertKey + +tls.JournalCertKey + + + +tls.JournalCA->tls.JournalCertKey + + - + kubeconfig.Admin->bootstrap.Bootstrap - - + + - + Target Cluster - -Target Cluster + +Target Cluster - + kubeconfig.Admin->Target Cluster - - - - - -kubeconfig.Admin->cluster.Cluster - - + + - + kubeconfig.Kubelet->bootstrap.Bootstrap - - + + - + cluster.TerraformVariables->Target Cluster - - + + - + cluster.TerraformVariables->cluster.Cluster - - + + + + + +tls.JournalCertKey->Target Cluster + + - + cluster.Cluster->Target Cluster - - + + diff --git a/pkg/asset/cluster/cluster.go b/pkg/asset/cluster/cluster.go index 39a79c9da3e..36c8a96f43e 100644 --- a/pkg/asset/cluster/cluster.go +++ b/pkg/asset/cluster/cluster.go @@ -15,7 +15,6 @@ import ( "github.com/openshift/installer/pkg/asset/cluster/libvirt" "github.com/openshift/installer/pkg/asset/cluster/openstack" "github.com/openshift/installer/pkg/asset/installconfig" - "github.com/openshift/installer/pkg/asset/kubeconfig" "github.com/openshift/installer/pkg/asset/password" "github.com/openshift/installer/pkg/terraform" "github.com/openshift/installer/pkg/types" @@ -50,7 +49,6 @@ func (c *Cluster) Dependencies() []asset.Asset { return []asset.Asset{ &installconfig.InstallConfig{}, &TerraformVariables{}, - &kubeconfig.Admin{}, &password.KubeadminPassword{}, } } @@ -59,9 +57,8 @@ func (c *Cluster) Dependencies() []asset.Asset { func (c *Cluster) Generate(parents asset.Parents) (err error) { installConfig := &installconfig.InstallConfig{} terraformVariables := &TerraformVariables{} - adminKubeconfig := &kubeconfig.Admin{} kubeadminPassword := &password.KubeadminPassword{} - parents.Get(installConfig, terraformVariables, adminKubeconfig, kubeadminPassword) + parents.Get(installConfig, terraformVariables, kubeadminPassword) // Copy the terraform.tfvars to a temp directory where the terraform will be invoked within. tmpDir, err := ioutil.TempDir("", "openshift-install-") @@ -131,7 +128,6 @@ func (c *Cluster) Generate(parents asset.Parents) (err error) { } } - // TODO(yifan): Use the kubeconfig to verify the cluster is up. return err }