From d9212f58e4cf849697c81cd8df3b97fa0e8a7b4e Mon Sep 17 00:00:00 2001 From: staebler Date: Wed, 21 Nov 2018 15:37:53 -0500 Subject: [PATCH 01/13] tfvars: remove tectonic from names of tfvars json The tectonic prefix in the tfvars are redundant as it identifies the type of installer being used which is evident already by using that installer. Changes for https://jira.coreos.com/browse/CORS-878 --- data/data/aws/main.tf | 102 ++++++++++----------- data/data/aws/variables-aws.tf | 38 ++++---- data/data/config.tf | 10 +- data/data/libvirt/main.tf | 54 +++++------ data/data/libvirt/variables-libvirt.tf | 14 +-- data/data/openstack/main.tf | 86 ++++++++--------- data/data/openstack/variables-openstack.tf | 58 ++++++------ pkg/tfvars/aws/aws.go | 38 ++++---- pkg/tfvars/libvirt/libvirt.go | 12 +-- pkg/tfvars/openstack/openstack.go | 58 ++++++------ pkg/tfvars/tfvars.go | 8 +- 11 files changed, 239 insertions(+), 239 deletions(-) diff --git a/data/data/aws/main.tf b/data/data/aws/main.tf index f0fc7674747..cb674fca37f 100644 --- a/data/data/aws/main.tf +++ b/data/data/aws/main.tf @@ -1,65 +1,65 @@ locals { - private_endpoints = "${var.tectonic_aws_endpoints == "public" ? false : true}" - public_endpoints = "${var.tectonic_aws_endpoints == "private" ? false : true}" - private_zone_id = "${var.tectonic_aws_external_private_zone != "" ? var.tectonic_aws_external_private_zone : join("", aws_route53_zone.tectonic_int.*.zone_id)}" + private_endpoints = "${var.aws_endpoints == "public" ? false : true}" + public_endpoints = "${var.aws_endpoints == "private" ? false : true}" + private_zone_id = "${var.aws_external_private_zone != "" ? var.aws_external_private_zone : join("", aws_route53_zone.tectonic_int.*.zone_id)}" } provider "aws" { - region = "${var.tectonic_aws_region}" + region = "${var.aws_region}" version = "1.39.0" assume_role { - role_arn = "${var.tectonic_aws_installer_role == "" ? "" : "${var.tectonic_aws_installer_role}"}" - session_name = "TECTONIC_INSTALLER_${var.tectonic_cluster_name}" + role_arn = "${var.aws_installer_role == "" ? "" : "${var.aws_installer_role}"}" + session_name = "TECTONIC_INSTALLER_${var.cluster_name}" } } module "bootstrap" { source = "./bootstrap" - ami = "${var.tectonic_aws_ec2_ami_override}" - associate_public_ip_address = "${var.tectonic_aws_endpoints != "private"}" - cluster_name = "${var.tectonic_cluster_name}" - iam_role = "${var.tectonic_aws_master_iam_role_name}" + ami = "${var.aws_ec2_ami_override}" + associate_public_ip_address = "${var.aws_endpoints != "private"}" + cluster_name = "${var.cluster_name}" + iam_role = "${var.aws_master_iam_role_name}" ignition = "${var.ignition_bootstrap}" subnet_id = "${module.vpc.master_subnet_ids[0]}" target_group_arns = "${module.vpc.aws_lb_target_group_arns}" target_group_arns_length = "${module.vpc.aws_lb_target_group_arns_length}" - vpc_security_group_ids = ["${concat(var.tectonic_aws_master_extra_sg_ids, list(module.vpc.master_sg_id))}"] + vpc_security_group_ids = ["${concat(var.aws_master_extra_sg_ids, list(module.vpc.master_sg_id))}"] tags = "${merge(map( - "Name", "${var.tectonic_cluster_name}-bootstrap", - "tectonicClusterID", "${var.tectonic_cluster_id}" - ), var.tectonic_aws_extra_tags)}" + "Name", "${var.cluster_name}-bootstrap", + "tectonicClusterID", "${var.cluster_id}" + ), var.aws_extra_tags)}" } module "masters" { source = "./master" - base_domain = "${var.tectonic_base_domain}" - cluster_id = "${var.tectonic_cluster_id}" - cluster_name = "${var.tectonic_cluster_name}" - ec2_type = "${var.tectonic_aws_master_ec2_type}" - extra_tags = "${var.tectonic_aws_extra_tags}" - instance_count = "${var.tectonic_master_count}" - master_iam_role = "${var.tectonic_aws_master_iam_role_name}" - master_sg_ids = "${concat(var.tectonic_aws_master_extra_sg_ids, list(module.vpc.master_sg_id))}" + base_domain = "${var.base_domain}" + cluster_id = "${var.cluster_id}" + cluster_name = "${var.cluster_name}" + ec2_type = "${var.aws_master_ec2_type}" + extra_tags = "${var.aws_extra_tags}" + instance_count = "${var.master_count}" + master_iam_role = "${var.aws_master_iam_role_name}" + master_sg_ids = "${concat(var.aws_master_extra_sg_ids, list(module.vpc.master_sg_id))}" public_endpoints = "${local.public_endpoints}" - root_volume_iops = "${var.tectonic_aws_master_root_volume_iops}" - root_volume_size = "${var.tectonic_aws_master_root_volume_size}" - root_volume_type = "${var.tectonic_aws_master_root_volume_type}" + root_volume_iops = "${var.aws_master_root_volume_iops}" + root_volume_size = "${var.aws_master_root_volume_size}" + root_volume_type = "${var.aws_master_root_volume_type}" subnet_ids = "${module.vpc.master_subnet_ids}" target_group_arns = "${module.vpc.aws_lb_target_group_arns}" target_group_arns_length = "${module.vpc.aws_lb_target_group_arns_length}" - ec2_ami = "${var.tectonic_aws_ec2_ami_override}" + ec2_ami = "${var.aws_ec2_ami_override}" user_data_ign = "${var.ignition_master}" } module "iam" { source = "./iam" - cluster_name = "${var.tectonic_cluster_name}" - worker_iam_role = "${var.tectonic_aws_worker_iam_role_name}" + cluster_name = "${var.cluster_name}" + worker_iam_role = "${var.aws_worker_iam_role_name}" } module "dns" { @@ -69,13 +69,13 @@ module "dns" { api_external_lb_zone_id = "${module.vpc.aws_lb_api_external_zone_id}" api_internal_lb_dns_name = "${module.vpc.aws_lb_api_internal_dns_name}" api_internal_lb_zone_id = "${module.vpc.aws_lb_api_internal_zone_id}" - base_domain = "${var.tectonic_base_domain}" - cluster_name = "${var.tectonic_cluster_name}" + base_domain = "${var.base_domain}" + cluster_name = "${var.cluster_name}" elb_alias_enabled = true - master_count = "${var.tectonic_master_count}" + master_count = "${var.master_count}" private_zone_id = "${local.private_zone_id}" external_vpc_id = "${module.vpc.vpc_id}" - extra_tags = "${var.tectonic_aws_extra_tags}" + extra_tags = "${var.aws_extra_tags}" private_endpoints = "${local.private_endpoints}" public_endpoints = "${local.public_endpoints}" } @@ -83,30 +83,30 @@ module "dns" { module "vpc" { source = "./vpc" - base_domain = "${var.tectonic_base_domain}" - cidr_block = "${var.tectonic_aws_vpc_cidr_block}" - cluster_id = "${var.tectonic_cluster_id}" - cluster_name = "${var.tectonic_cluster_name}" - external_vpc_id = "${var.tectonic_aws_external_vpc_id}" + base_domain = "${var.base_domain}" + cidr_block = "${var.aws_vpc_cidr_block}" + cluster_id = "${var.cluster_id}" + cluster_name = "${var.cluster_name}" + external_vpc_id = "${var.aws_external_vpc_id}" - external_master_subnet_ids = "${compact(var.tectonic_aws_external_master_subnet_ids)}" - external_worker_subnet_ids = "${compact(var.tectonic_aws_external_worker_subnet_ids)}" - extra_tags = "${var.tectonic_aws_extra_tags}" + external_master_subnet_ids = "${compact(var.aws_external_master_subnet_ids)}" + external_worker_subnet_ids = "${compact(var.aws_external_worker_subnet_ids)}" + extra_tags = "${var.aws_extra_tags}" // empty map subnet_configs will have the vpc module creating subnets in all availabile AZs - new_master_subnet_configs = "${var.tectonic_aws_master_custom_subnets}" - new_worker_subnet_configs = "${var.tectonic_aws_worker_custom_subnets}" + new_master_subnet_configs = "${var.aws_master_custom_subnets}" + new_worker_subnet_configs = "${var.aws_worker_custom_subnets}" private_master_endpoints = "${local.private_endpoints}" public_master_endpoints = "${local.public_endpoints}" } resource "aws_route53_record" "etcd_a_nodes" { - count = "${var.tectonic_master_count}" + count = "${var.master_count}" type = "A" ttl = "60" zone_id = "${local.private_zone_id}" - name = "${var.tectonic_cluster_name}-etcd-${count.index}" + name = "${var.cluster_name}-etcd-${count.index}" records = ["${module.masters.ip_addresses[count.index]}"] } @@ -114,19 +114,19 @@ resource "aws_route53_record" "etcd_cluster" { type = "SRV" ttl = "60" zone_id = "${local.private_zone_id}" - name = "_etcd-server-ssl._tcp.${var.tectonic_cluster_name}" + name = "_etcd-server-ssl._tcp.${var.cluster_name}" records = ["${formatlist("0 10 2380 %s", aws_route53_record.etcd_a_nodes.*.fqdn)}"] } resource "aws_route53_zone" "tectonic_int" { - count = "${local.private_endpoints ? "${var.tectonic_aws_external_private_zone == "" ? 1 : 0 }" : 0}" + count = "${local.private_endpoints ? "${var.aws_external_private_zone == "" ? 1 : 0 }" : 0}" vpc_id = "${module.vpc.vpc_id}" - name = "${var.tectonic_base_domain}" + name = "${var.base_domain}" force_destroy = true tags = "${merge(map( - "Name", "${var.tectonic_cluster_name}_tectonic_int", - "KubernetesCluster", "${var.tectonic_cluster_name}", - "tectonicClusterID", "${var.tectonic_cluster_id}" - ), var.tectonic_aws_extra_tags)}" + "Name", "${var.cluster_name}_tectonic_int", + "KubernetesCluster", "${var.cluster_name}", + "tectonicClusterID", "${var.cluster_id}" + ), var.aws_extra_tags)}" } diff --git a/data/data/aws/variables-aws.tf b/data/data/aws/variables-aws.tf index 14f58fa2f0e..4a032f92c50 100644 --- a/data/data/aws/variables-aws.tf +++ b/data/data/aws/variables-aws.tf @@ -1,4 +1,4 @@ -variable "tectonic_aws_config_version" { +variable "aws_config_version" { description = < Date: Wed, 21 Nov 2018 22:47:58 -0500 Subject: [PATCH 02/13] terraform: remove tectonic references from terraform config file This makes the corresponding change in the terraform to match the removal of the terraform prefix in the tfvars json. Changes for https://jira.coreos.com/browse/CORS-878 --- data/data/config.tf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/data/data/config.tf b/data/data/config.tf index 2d42150b72a..8e3e098df35 100644 --- a/data/data/config.tf +++ b/data/data/config.tf @@ -31,7 +31,7 @@ variable "cluster_name" { description = < Date: Wed, 21 Nov 2018 23:01:21 -0500 Subject: [PATCH 03/13] terraform: remove references to tectonic from aws terraform modules The session name when connecting to AWS is changed from starting with TECTONIC_INSTALLER_ to starting with OPENSHIFT_INSTALLER. The terraform name of the internal route53 zone is changed from terraform_int to int. The Name tag of the zone is changed from ending with _tectonic_int to ending with _int. The terraform name of the base route53 zone is changed from tectonic to base. The terraform name of the api route53 records are changed from tectonic_api_external and tectonic_api_internal to api_external and api_internal, respectively. Changes for https://jira.coreos.com/browse/CORS-878 --- data/data/aws/main.tf | 8 ++++---- data/data/aws/route53/{tectonic.tf => base.tf} | 8 ++++---- data/data/aws/route53/master.tf | 2 +- data/data/aws/route53/worker.tf | 4 ++-- data/data/aws/variables-aws.tf | 14 +++++++------- 5 files changed, 18 insertions(+), 18 deletions(-) rename data/data/aws/route53/{tectonic.tf => base.tf} (81%) diff --git a/data/data/aws/main.tf b/data/data/aws/main.tf index cb674fca37f..3ba748f659e 100644 --- a/data/data/aws/main.tf +++ b/data/data/aws/main.tf @@ -1,7 +1,7 @@ locals { private_endpoints = "${var.aws_endpoints == "public" ? false : true}" public_endpoints = "${var.aws_endpoints == "private" ? false : true}" - private_zone_id = "${var.aws_external_private_zone != "" ? var.aws_external_private_zone : join("", aws_route53_zone.tectonic_int.*.zone_id)}" + private_zone_id = "${var.aws_external_private_zone != "" ? var.aws_external_private_zone : join("", aws_route53_zone.int.*.zone_id)}" } provider "aws" { @@ -10,7 +10,7 @@ provider "aws" { assume_role { role_arn = "${var.aws_installer_role == "" ? "" : "${var.aws_installer_role}"}" - session_name = "TECTONIC_INSTALLER_${var.cluster_name}" + session_name = "OPENSHIFT_INSTALLER_${var.cluster_name}" } } @@ -118,14 +118,14 @@ resource "aws_route53_record" "etcd_cluster" { records = ["${formatlist("0 10 2380 %s", aws_route53_record.etcd_a_nodes.*.fqdn)}"] } -resource "aws_route53_zone" "tectonic_int" { +resource "aws_route53_zone" "int" { count = "${local.private_endpoints ? "${var.aws_external_private_zone == "" ? 1 : 0 }" : 0}" vpc_id = "${module.vpc.vpc_id}" name = "${var.base_domain}" force_destroy = true tags = "${merge(map( - "Name", "${var.cluster_name}_tectonic_int", + "Name", "${var.cluster_name}_int", "KubernetesCluster", "${var.cluster_name}", "tectonicClusterID", "${var.cluster_id}" ), var.aws_extra_tags)}" diff --git a/data/data/aws/route53/tectonic.tf b/data/data/aws/route53/base.tf similarity index 81% rename from data/data/aws/route53/tectonic.tf rename to data/data/aws/route53/base.tf index dec20b23af1..6e53975ffc9 100644 --- a/data/data/aws/route53/tectonic.tf +++ b/data/data/aws/route53/base.tf @@ -3,17 +3,17 @@ locals { private_endpoints_count = "${var.private_endpoints ? 1 : 0}" } -data "aws_route53_zone" "tectonic" { +data "aws_route53_zone" "base" { name = "${var.base_domain}" } locals { - public_zone_id = "${join("", data.aws_route53_zone.tectonic.*.zone_id)}" + public_zone_id = "${join("", data.aws_route53_zone.base.*.zone_id)}" zone_id = "${var.private_endpoints ? var.private_zone_id : local.public_zone_id}" } -resource "aws_route53_record" "tectonic_api_external" { +resource "aws_route53_record" "api_external" { count = "${var.elb_alias_enabled ? local.public_endpoints_count : 0}" zone_id = "${local.public_zone_id}" @@ -27,7 +27,7 @@ resource "aws_route53_record" "tectonic_api_external" { } } -resource "aws_route53_record" "tectonic_api_internal" { +resource "aws_route53_record" "api_internal" { count = "${var.elb_alias_enabled ? local.private_endpoints_count : 0}" zone_id = "${var.private_zone_id}" diff --git a/data/data/aws/route53/master.tf b/data/data/aws/route53/master.tf index bed1331372b..0d0d3b880e1 100644 --- a/data/data/aws/route53/master.tf +++ b/data/data/aws/route53/master.tf @@ -1,6 +1,6 @@ resource "aws_route53_record" "master_nodes" { count = "${var.elb_alias_enabled ? 0 : var.master_count}" - zone_id = "${data.aws_route53_zone.tectonic.zone_id}" + zone_id = "${data.aws_route53_zone.base.zone_id}" name = "${var.cluster_name}-master-${count.index}" type = "A" ttl = "60" diff --git a/data/data/aws/route53/worker.tf b/data/data/aws/route53/worker.tf index 5c782ecaf94..5921cb42817 100644 --- a/data/data/aws/route53/worker.tf +++ b/data/data/aws/route53/worker.tf @@ -1,6 +1,6 @@ resource "aws_route53_record" "worker_nodes" { count = "${var.elb_alias_enabled ? 0 : var.worker_count}" - zone_id = "${data.aws_route53_zone.tectonic.zone_id}" + zone_id = "${data.aws_route53_zone.base.zone_id}" name = "${var.cluster_name}-worker-${count.index}" type = "A" ttl = "60" @@ -10,7 +10,7 @@ resource "aws_route53_record" "worker_nodes" { resource "aws_route53_record" "worker_nodes_public" { // hack: worker_public_ips_enabled is a workaround for https://github.com/hashicorp/terraform/issues/10857 count = "${var.worker_public_ips_enabled ? var.worker_count : 0}" - zone_id = "${data.aws_route53_zone.tectonic.zone_id}" + zone_id = "${data.aws_route53_zone.base.zone_id}" name = "${var.cluster_name}-worker-${count.index}-public" type = "A" ttl = "60" diff --git a/data/data/aws/variables-aws.tf b/data/data/aws/variables-aws.tf index 4a032f92c50..df672aeaff4 100644 --- a/data/data/aws/variables-aws.tf +++ b/data/data/aws/variables-aws.tf @@ -32,7 +32,7 @@ EOF default = [] } -variable "tectonic_aws_vpc_cidr_block" { +variable "aws_vpc_cidr_block" { type = "string" description = < Date: Wed, 21 Nov 2018 23:02:26 -0500 Subject: [PATCH 04/13] terraform: remove references to tectonic from libvirt terraform modules The terraform name of the libvirt network is changed from tectonic_net to net. Changes for https://jira.coreos.com/browse/CORS-878 --- data/data/libvirt/main.tf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/data/data/libvirt/main.tf b/data/data/libvirt/main.tf index 0ac46c7324b..2b8d7321c1c 100644 --- a/data/data/libvirt/main.tf +++ b/data/data/libvirt/main.tf @@ -16,7 +16,7 @@ module "bootstrap" { base_volume_id = "${module.volume.coreos_base_volume_id}" cluster_name = "${var.cluster_name}" ignition = "${var.ignition_bootstrap}" - network_id = "${libvirt_network.tectonic_net.id}" + network_id = "${libvirt_network.net.id}" } resource "libvirt_volume" "master" { @@ -30,7 +30,7 @@ resource "libvirt_ignition" "master" { content = "${var.ignition_master}" } -resource "libvirt_network" "tectonic_net" { +resource "libvirt_network" "net" { name = "${var.cluster_name}" mode = "nat" @@ -79,7 +79,7 @@ resource "libvirt_domain" "master" { } network_interface { - network_id = "${libvirt_network.tectonic_net.id}" + network_id = "${libvirt_network.net.id}" hostname = "${var.cluster_name}-master-${count.index}" addresses = ["${var.libvirt_master_ips[count.index]}"] } From f621260e120457e1eb0e46c9aac2c0929afc3381 Mon Sep 17 00:00:00 2001 From: staebler Date: Wed, 21 Nov 2018 23:04:46 -0500 Subject: [PATCH 05/13] terraform: remove references to tectonic from openstack terraform modules The terraform name of the openstack object storage container is changed from terraform to container. Changes for https://jira.coreos.com/browse/CORS-878 --- data/data/openstack/main.tf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/data/openstack/main.tf b/data/data/openstack/main.tf index fe052677930..bdc8852bf4e 100644 --- a/data/data/openstack/main.tf +++ b/data/data/openstack/main.tf @@ -27,7 +27,7 @@ provider "openstack" { module "bootstrap" { source = "./bootstrap" - swift_container = "${openstack_objectstorage_container_v1.tectonic.name}" + swift_container = "${openstack_objectstorage_container_v1.container.name}" cluster_name = "${var.cluster_name}" cluster_id = "${var.cluster_id}" image_name = "${var.openstack_base_image}" @@ -62,7 +62,7 @@ module "topology" { masters_count = "${var.master_count}" } -resource "openstack_objectstorage_container_v1" "tectonic" { +resource "openstack_objectstorage_container_v1" "container" { name = "${lower(var.cluster_name)}.${var.base_domain}" metadata = "${merge(map( From 2a94e997bcc8b333dfb6c33cb7aca21e66d52e1b Mon Sep 17 00:00:00 2001 From: staebler Date: Wed, 21 Nov 2018 23:28:33 -0500 Subject: [PATCH 06/13] data/bootstrap: remove tectonic references from bootstrap data Change the directory of bootstrap files from /opt/tectonic to /opt/openshift. Change the directory of files laid down by the Tectonic Manifests asset from tectonic to openshift. Change the name of the service that lays down OpenShift manifests from tectonic.service to openshift.service. Changes for https://jira.coreos.com/browse/CORS-878 --- .../kube-apiserver-config-overrides.yaml | 0 ...e-controller-manager-config-overrides.yaml | 0 .../kube-scheduler-config-overrides.yaml | 0 .../files/usr/local/bin/bootkube.sh.template | 24 +++++++++---------- .../local/bin/{tectonic.sh => openshift.sh} | 4 ++-- .../bootstrap/systemd/units/bootkube.service | 4 ++-- .../bootstrap/systemd/units/openshift.service | 12 ++++++++++ .../bootstrap/systemd/units/progress.service | 10 ++++---- .../bootstrap/systemd/units/tectonic.service | 12 ---------- pkg/asset/ignition/bootstrap/bootstrap.go | 2 +- pkg/asset/manifests/tectonic.go | 6 ++--- 11 files changed, 37 insertions(+), 37 deletions(-) rename data/data/bootstrap/files/opt/{tectonic => openshift}/bootkube-config-overrides/kube-apiserver-config-overrides.yaml (100%) rename data/data/bootstrap/files/opt/{tectonic => openshift}/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml (100%) rename data/data/bootstrap/files/opt/{tectonic => openshift}/bootkube-config-overrides/kube-scheduler-config-overrides.yaml (100%) rename data/data/bootstrap/files/usr/local/bin/{tectonic.sh => openshift.sh} (94%) create mode 100644 data/data/bootstrap/systemd/units/openshift.service delete mode 100644 data/data/bootstrap/systemd/units/tectonic.service diff --git a/data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-apiserver-config-overrides.yaml b/data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-apiserver-config-overrides.yaml similarity index 100% rename from data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-apiserver-config-overrides.yaml rename to data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-apiserver-config-overrides.yaml diff --git a/data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml b/data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml similarity index 100% rename from data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml rename to data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml diff --git a/data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-scheduler-config-overrides.yaml b/data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-scheduler-config-overrides.yaml similarity index 100% rename from data/data/bootstrap/files/opt/tectonic/bootkube-config-overrides/kube-scheduler-config-overrides.yaml rename to data/data/bootstrap/files/opt/openshift/bootkube-config-overrides/kube-scheduler-config-overrides.yaml diff --git a/data/data/bootstrap/files/usr/local/bin/bootkube.sh.template b/data/data/bootstrap/files/usr/local/bin/bootkube.sh.template index 72a252a8472..2fbdbea1958 100755 --- a/data/data/bootstrap/files/usr/local/bin/bootkube.sh.template +++ b/data/data/bootstrap/files/usr/local/bin/bootkube.sh.template @@ -64,7 +64,7 @@ then --asset-output-dir=/assets/kube-apiserver-bootstrap \ --config-output-file=/assets/kube-apiserver-bootstrap/config \ --config-override-files=/assets/bootkube-config-overrides/kube-apiserver-config-overrides.yaml \ - --cluster-config-file=/assets/tectonic/99_openshift-cluster-api_cluster.yaml + --cluster-config-file=/assets/openshift/99_openshift-cluster-api_cluster.yaml cp kube-apiserver-bootstrap/config /etc/kubernetes/bootstrap-configs/kube-apiserver-config.yaml cp kube-apiserver-bootstrap/bootstrap-manifests/* bootstrap-manifests/ @@ -85,7 +85,7 @@ then --asset-output-dir=/assets/kube-controller-manager-bootstrap \ --config-output-file=/assets/kube-controller-manager-bootstrap/config \ --config-override-files=/assets/bootkube-config-overrides/kube-controller-manager-config-overrides.yaml \ - --cluster-config-file=/assets/tectonic/99_openshift-cluster-api_cluster.yaml + --cluster-config-file=/assets/openshift/99_openshift-cluster-api_cluster.yaml cp kube-controller-manager-bootstrap/config /etc/kubernetes/bootstrap-configs/kube-controller-manager-config.yaml cp kube-controller-manager-bootstrap/bootstrap-manifests/* bootstrap-manifests/ @@ -160,14 +160,14 @@ trap "podman rm --force etcd-signer" ERR podman run \ --name etcd-signer \ --detach \ - --volume /opt/tectonic/tls:/opt/tectonic/tls:ro,z \ + --volume /opt/openshift/tls:/opt/openshift/tls:ro,z \ --network host \ "{{.EtcdCertSignerImage}}" \ serve \ - --cacrt=/opt/tectonic/tls/etcd-client-ca.crt \ - --cakey=/opt/tectonic/tls/etcd-client-ca.key \ - --servcrt=/opt/tectonic/tls/apiserver.crt \ - --servkey=/opt/tectonic/tls/apiserver.key \ + --cacrt=/opt/openshift/tls/etcd-client-ca.crt \ + --cakey=/opt/openshift/tls/etcd-client-ca.key \ + --servcrt=/opt/openshift/tls/apiserver.crt \ + --servkey=/opt/openshift/tls/apiserver.key \ --address=0.0.0.0:6443 \ --csrdir=/tmp \ --peercertdur=26280h \ @@ -182,13 +182,13 @@ until podman run \ --network host \ --name etcdctl \ --env ETCDCTL_API=3 \ - --volume /opt/tectonic/tls:/opt/tectonic/tls:ro,z \ + --volume /opt/openshift/tls:/opt/openshift/tls:ro,z \ "{{.EtcdctlImage}}" \ /usr/local/bin/etcdctl \ --dial-timeout=10m \ - --cacert=/opt/tectonic/tls/etcd-client-ca.crt \ - --cert=/opt/tectonic/tls/etcd-client.crt \ - --key=/opt/tectonic/tls/etcd-client.key \ + --cacert=/opt/openshift/tls/etcd-client-ca.crt \ + --cert=/opt/openshift/tls/etcd-client.crt \ + --key=/opt/openshift/tls/etcd-client.key \ --endpoints={{.EtcdCluster}} \ endpoint health do @@ -213,4 +213,4 @@ podman run \ start --asset-dir=/assets --required-pods openshift-kube-apiserver/openshift-kube-apiserver,openshift-kube-scheduler/openshift-kube-scheduler,openshift-kube-controller-manager/openshift-kube-controller-manager,openshift-cluster-version/cluster-version-operator # Workaround for https://github.com/opencontainers/runc/pull/1807 -touch /opt/tectonic/.bootkube.done +touch /opt/openshift/.bootkube.done diff --git a/data/data/bootstrap/files/usr/local/bin/tectonic.sh b/data/data/bootstrap/files/usr/local/bin/openshift.sh similarity index 94% rename from data/data/bootstrap/files/usr/local/bin/tectonic.sh rename to data/data/bootstrap/files/usr/local/bin/openshift.sh index 5429597045e..6dcdbb52fd9 100755 --- a/data/data/bootstrap/files/usr/local/bin/tectonic.sh +++ b/data/data/bootstrap/files/usr/local/bin/openshift.sh @@ -66,6 +66,6 @@ do done # Workaround for https://github.com/opencontainers/runc/pull/1807 -touch /opt/tectonic/.tectonic.done +touch /opt/openshift/.openshift.done -echo "Tectonic installation is done" +echo "OpenShift installation is done" diff --git a/data/data/bootstrap/systemd/units/bootkube.service b/data/data/bootstrap/systemd/units/bootkube.service index 237e8cdffb6..f0f71cd1d64 100644 --- a/data/data/bootstrap/systemd/units/bootkube.service +++ b/data/data/bootstrap/systemd/units/bootkube.service @@ -2,10 +2,10 @@ Description=Bootstrap a Kubernetes cluster Wants=kubelet.service After=kubelet.service -ConditionPathExists=!/opt/tectonic/.bootkube.done +ConditionPathExists=!/opt/openshift/.bootkube.done [Service] -WorkingDirectory=/opt/tectonic +WorkingDirectory=/opt/openshift ExecStart=/usr/local/bin/bootkube.sh Restart=on-failure diff --git a/data/data/bootstrap/systemd/units/openshift.service b/data/data/bootstrap/systemd/units/openshift.service new file mode 100644 index 00000000000..c09bc11e709 --- /dev/null +++ b/data/data/bootstrap/systemd/units/openshift.service @@ -0,0 +1,12 @@ +[Unit] +Description=Bootstrap an OpenShift cluster +Wants=bootkube.service +After=bootkube.service +ConditionPathExists=!/opt/openshift/.openshift.done + +[Service] +WorkingDirectory=/opt/openshift/openshift +ExecStart=/usr/local/bin/openshift.sh /opt/openshift/auth/kubeconfig + +Restart=on-failure +RestartSec=5s diff --git a/data/data/bootstrap/systemd/units/progress.service b/data/data/bootstrap/systemd/units/progress.service index 1faaa31006b..57a3a532d22 100644 --- a/data/data/bootstrap/systemd/units/progress.service +++ b/data/data/bootstrap/systemd/units/progress.service @@ -1,14 +1,14 @@ [Unit] Description=Report the completion of the cluster bootstrap process # Workaround for https://github.com/systemd/systemd/issues/1312 -Wants=bootkube.service tectonic.service -After=bootkube.service tectonic.service +Wants=bootkube.service openshift.service +After=bootkube.service openshift.service [Service] # Workaround for https://github.com/systemd/systemd/issues/1312 and https://github.com/opencontainers/runc/pull/1807 -ExecStartPre=/usr/bin/test -f /opt/tectonic/.bootkube.done -ExecStartPre=/usr/bin/test -f /opt/tectonic/.tectonic.done -ExecStart=/usr/local/bin/report-progress.sh /opt/tectonic/auth/kubeconfig bootstrap-complete "cluster bootstrapping has completed" +ExecStartPre=/usr/bin/test -f /opt/openshift/.bootkube.done +ExecStartPre=/usr/bin/test -f /opt/openshift/.openshift.done +ExecStart=/usr/local/bin/report-progress.sh /opt/openshift/auth/kubeconfig bootstrap-complete "cluster bootstrapping has completed" Restart=on-failure RestartSec=5s diff --git a/data/data/bootstrap/systemd/units/tectonic.service b/data/data/bootstrap/systemd/units/tectonic.service deleted file mode 100644 index bf40df31619..00000000000 --- a/data/data/bootstrap/systemd/units/tectonic.service +++ /dev/null @@ -1,12 +0,0 @@ -[Unit] -Description=Bootstrap a Tectonic cluster -Wants=bootkube.service -After=bootkube.service -ConditionPathExists=!/opt/tectonic/.tectonic.done - -[Service] -WorkingDirectory=/opt/tectonic/tectonic -ExecStart=/usr/local/bin/tectonic.sh /opt/tectonic/auth/kubeconfig - -Restart=on-failure -RestartSec=5s diff --git a/pkg/asset/ignition/bootstrap/bootstrap.go b/pkg/asset/ignition/bootstrap/bootstrap.go index 03ae59a8ec6..60d02198f98 100644 --- a/pkg/asset/ignition/bootstrap/bootstrap.go +++ b/pkg/asset/ignition/bootstrap/bootstrap.go @@ -29,7 +29,7 @@ import ( ) const ( - rootDir = "/opt/tectonic" + rootDir = "/opt/openshift" defaultReleaseImage = "registry.svc.ci.openshift.org/openshift/origin-release:v4.0" bootstrapIgnFilename = "bootstrap.ign" ) diff --git a/pkg/asset/manifests/tectonic.go b/pkg/asset/manifests/tectonic.go index 285e5a8c2bb..6d7a8a0ebcd 100644 --- a/pkg/asset/manifests/tectonic.go +++ b/pkg/asset/manifests/tectonic.go @@ -16,7 +16,7 @@ import ( ) const ( - tectonicManifestDir = "tectonic" + openshiftManifestDir = "openshift" ) var ( @@ -127,7 +127,7 @@ func (t *Tectonic) Generate(dependencies asset.Parents) error { t.FileList = []*asset.File{} for name, data := range assetData { t.FileList = append(t.FileList, &asset.File{ - Filename: filepath.Join(tectonicManifestDir, name), + Filename: filepath.Join(openshiftManifestDir, name), Data: data, }) } @@ -142,7 +142,7 @@ func (t *Tectonic) Files() []*asset.File { // Load returns the tectonic asset from disk. func (t *Tectonic) Load(f asset.FileFetcher) (bool, error) { - fileList, err := f.FetchByPattern(filepath.Join(tectonicManifestDir, "*")) + fileList, err := f.FetchByPattern(filepath.Join(openshiftManifestDir, "*")) if err != nil { return false, err } From bc1508fb0342d0ad529897502bdaf95b72ec20f4 Mon Sep 17 00:00:00 2001 From: staebler Date: Wed, 21 Nov 2018 23:30:02 -0500 Subject: [PATCH 07/13] data/manifests: remove tectonic references from manifests data Change directory for openshift manifests from data/data/manifests/tectonic to data/data/manifests/openshift. Chnages for https://jira.coreos.com/browse/CORS-878 --- .../data/manifests/{tectonic => openshift}/binding-discovery.yaml | 0 .../{tectonic => openshift}/cloud-creds-secret.yaml.template | 0 .../kubeadmin-password-secret.yaml.template | 0 .../role-cloud-creds-secret-reader.yaml.template | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename data/data/manifests/{tectonic => openshift}/binding-discovery.yaml (100%) rename data/data/manifests/{tectonic => openshift}/cloud-creds-secret.yaml.template (100%) rename data/data/manifests/{tectonic => openshift}/kubeadmin-password-secret.yaml.template (100%) rename data/data/manifests/{tectonic => openshift}/role-cloud-creds-secret-reader.yaml.template (100%) diff --git a/data/data/manifests/tectonic/binding-discovery.yaml b/data/data/manifests/openshift/binding-discovery.yaml similarity index 100% rename from data/data/manifests/tectonic/binding-discovery.yaml rename to data/data/manifests/openshift/binding-discovery.yaml diff --git a/data/data/manifests/tectonic/cloud-creds-secret.yaml.template b/data/data/manifests/openshift/cloud-creds-secret.yaml.template similarity index 100% rename from data/data/manifests/tectonic/cloud-creds-secret.yaml.template rename to data/data/manifests/openshift/cloud-creds-secret.yaml.template diff --git a/data/data/manifests/tectonic/kubeadmin-password-secret.yaml.template b/data/data/manifests/openshift/kubeadmin-password-secret.yaml.template similarity index 100% rename from data/data/manifests/tectonic/kubeadmin-password-secret.yaml.template rename to data/data/manifests/openshift/kubeadmin-password-secret.yaml.template diff --git a/data/data/manifests/tectonic/role-cloud-creds-secret-reader.yaml.template b/data/data/manifests/openshift/role-cloud-creds-secret-reader.yaml.template similarity index 100% rename from data/data/manifests/tectonic/role-cloud-creds-secret-reader.yaml.template rename to data/data/manifests/openshift/role-cloud-creds-secret-reader.yaml.template From c7809ca53f66a4c5dbf2d7b14b756338b1b1993e Mon Sep 17 00:00:00 2001 From: staebler Date: Thu, 22 Nov 2018 17:04:37 -0500 Subject: [PATCH 08/13] asset/manifests: rename tectonic manifests asset to openshift manifests Changes for https://jira.coreos.com/browse/CORS-878 --- cmd/openshift-install/create.go | 2 +- pkg/asset/ignition/bootstrap/bootstrap.go | 8 ++--- .../manifests/{tectonic.go => openshift.go} | 30 +++++++++---------- pkg/asset/manifests/template.go | 2 +- 4 files changed, 21 insertions(+), 21 deletions(-) rename pkg/asset/manifests/{tectonic.go => openshift.go} (86%) diff --git a/cmd/openshift-install/create.go b/cmd/openshift-install/create.go index 5bc0c52ca1b..5b7ce3836cc 100644 --- a/cmd/openshift-install/create.go +++ b/cmd/openshift-install/create.go @@ -57,7 +57,7 @@ var ( // FIXME: add longer descriptions for our commands with examples for better UX. // Long: "", }, - assets: []asset.WritableAsset{&manifests.Manifests{}, &manifests.Tectonic{}}, + assets: []asset.WritableAsset{&manifests.Manifests{}, &manifests.Openshift{}}, } manifestTemplatesTarget = target{ diff --git a/pkg/asset/ignition/bootstrap/bootstrap.go b/pkg/asset/ignition/bootstrap/bootstrap.go index 60d02198f98..09dd63faf16 100644 --- a/pkg/asset/ignition/bootstrap/bootstrap.go +++ b/pkg/asset/ignition/bootstrap/bootstrap.go @@ -72,7 +72,7 @@ func (a *Bootstrap) Dependencies() []asset.Asset { &kubeconfig.Admin{}, &kubeconfig.Kubelet{}, &manifests.Manifests{}, - &manifests.Tectonic{}, + &manifests.Openshift{}, } } @@ -281,8 +281,8 @@ func (a *Bootstrap) addParentFiles(dependencies asset.Parents) { adminKubeconfig := &kubeconfig.Admin{} kubeletKubeconfig := &kubeconfig.Kubelet{} mfsts := &manifests.Manifests{} - tectonic := &manifests.Tectonic{} - dependencies.Get(adminKubeconfig, kubeletKubeconfig, mfsts, tectonic) + openshiftManifests := &manifests.Openshift{} + dependencies.Get(adminKubeconfig, kubeletKubeconfig, mfsts, openshiftManifests) a.Config.Storage.Files = append( a.Config.Storage.Files, @@ -299,7 +299,7 @@ func (a *Bootstrap) addParentFiles(dependencies asset.Parents) { ) a.Config.Storage.Files = append( a.Config.Storage.Files, - ignition.FilesFromAsset(rootDir, 0644, tectonic)..., + ignition.FilesFromAsset(rootDir, 0644, openshiftManifests)..., ) for _, asset := range []asset.WritableAsset{ diff --git a/pkg/asset/manifests/tectonic.go b/pkg/asset/manifests/openshift.go similarity index 86% rename from pkg/asset/manifests/tectonic.go rename to pkg/asset/manifests/openshift.go index 6d7a8a0ebcd..bff16fdf3ae 100644 --- a/pkg/asset/manifests/tectonic.go +++ b/pkg/asset/manifests/openshift.go @@ -20,22 +20,22 @@ const ( ) var ( - _ asset.WritableAsset = (*Tectonic)(nil) + _ asset.WritableAsset = (*Openshift)(nil) ) -// Tectonic generates the dependent resource manifests for tectonic (as against bootkube) -type Tectonic struct { +// Openshift generates the dependent resource manifests for openShift (as against bootkube) +type Openshift struct { FileList []*asset.File } // Name returns a human friendly name for the operator -func (t *Tectonic) Name() string { - return "Tectonic Manifests" +func (o *Openshift) Name() string { + return "Openshift Manifests" } // Dependencies returns all of the dependencies directly needed by the -// Tectonic asset -func (t *Tectonic) Dependencies() []asset.Asset { +// Openshift asset +func (o *Openshift) Dependencies() []asset.Asset { return []asset.Asset{ &installconfig.InstallConfig{}, &ClusterK8sIO{}, @@ -51,7 +51,7 @@ func (t *Tectonic) Dependencies() []asset.Asset { } // Generate generates the respective operator config.yml files -func (t *Tectonic) Generate(dependencies asset.Parents) error { +func (o *Openshift) Generate(dependencies asset.Parents) error { installConfig := &installconfig.InstallConfig{} kubeadminPassword := &password.KubeadminPassword{} clusterk8sio := &ClusterK8sIO{} @@ -94,7 +94,7 @@ func (t *Tectonic) Generate(dependencies asset.Parents) error { } } - templateData := &tectonicTemplateData{ + templateData := &openshiftTemplateData{ CloudCreds: cloudCreds, Base64EncodedKubeadminPwHash: base64.StdEncoding.EncodeToString(kubeadminPassword.PasswordHash), } @@ -124,9 +124,9 @@ func (t *Tectonic) Generate(dependencies asset.Parents) error { assetData["99_role-cloud-creds-secret-reader.yaml"] = applyTemplateData(roleCloudCredsSecretReader.Files()[0].Data, templateData) } - t.FileList = []*asset.File{} + o.FileList = []*asset.File{} for name, data := range assetData { - t.FileList = append(t.FileList, &asset.File{ + o.FileList = append(o.FileList, &asset.File{ Filename: filepath.Join(openshiftManifestDir, name), Data: data, }) @@ -136,12 +136,12 @@ func (t *Tectonic) Generate(dependencies asset.Parents) error { } // Files returns the files generated by the asset. -func (t *Tectonic) Files() []*asset.File { - return t.FileList +func (o *Openshift) Files() []*asset.File { + return o.FileList } -// Load returns the tectonic asset from disk. -func (t *Tectonic) Load(f asset.FileFetcher) (bool, error) { +// Load returns the openshift asset from disk. +func (o *Openshift) Load(f asset.FileFetcher) (bool, error) { fileList, err := f.FetchByPattern(filepath.Join(openshiftManifestDir, "*")) if err != nil { return false, err diff --git a/pkg/asset/manifests/template.go b/pkg/asset/manifests/template.go index ae6b3945260..f341ad972d6 100644 --- a/pkg/asset/manifests/template.go +++ b/pkg/asset/manifests/template.go @@ -35,7 +35,7 @@ type bootkubeTemplateData struct { EtcdEndpointDNSSuffix string } -type tectonicTemplateData struct { +type openshiftTemplateData struct { CloudCreds cloudCredsSecretData Base64EncodedKubeadminPwHash string } From 628521b2c54bccb74fa3d2e080f321d0db6ef677 Mon Sep 17 00:00:00 2001 From: staebler Date: Mon, 26 Nov 2018 15:10:14 -0500 Subject: [PATCH 09/13] asset/templates: move openshift manifest templates from manifests/tectonic to manifests/openshift Changes for https://jira.coreos.com/browse/CORS-878 --- pkg/asset/manifests/openshift.go | 18 +++++++++--------- pkg/asset/templates/content/helper.go | 12 ++++++------ .../binding-discovery.go | 4 ++-- .../cloud-creds-secret.go | 4 ++-- .../kubeadmin-password-secret.go | 4 ++-- .../role-cloud-creds-secret-reader.go | 4 ++-- pkg/asset/templates/templates.go | 18 +++++++++--------- 7 files changed, 32 insertions(+), 32 deletions(-) rename pkg/asset/templates/content/{tectonic => openshift}/binding-discovery.go (95%) rename pkg/asset/templates/content/{tectonic => openshift}/cloud-creds-secret.go (95%) rename pkg/asset/templates/content/{tectonic => openshift}/kubeadmin-password-secret.go (95%) rename pkg/asset/templates/content/{tectonic => openshift}/role-cloud-creds-secret-reader.go (95%) diff --git a/pkg/asset/manifests/openshift.go b/pkg/asset/manifests/openshift.go index bff16fdf3ae..1e00b600a22 100644 --- a/pkg/asset/manifests/openshift.go +++ b/pkg/asset/manifests/openshift.go @@ -12,7 +12,7 @@ import ( "github.com/openshift/installer/pkg/asset/installconfig" "github.com/openshift/installer/pkg/asset/machines" "github.com/openshift/installer/pkg/asset/password" - "github.com/openshift/installer/pkg/asset/templates/content/tectonic" + "github.com/openshift/installer/pkg/asset/templates/content/openshift" ) const ( @@ -43,10 +43,10 @@ func (o *Openshift) Dependencies() []asset.Asset { &machines.Master{}, &password.KubeadminPassword{}, - &tectonic.BindingDiscovery{}, - &tectonic.CloudCredsSecret{}, - &tectonic.KubeadminPasswordSecret{}, - &tectonic.RoleCloudCredsSecretReader{}, + &openshift.BindingDiscovery{}, + &openshift.CloudCredsSecret{}, + &openshift.KubeadminPasswordSecret{}, + &openshift.RoleCloudCredsSecretReader{}, } } @@ -99,10 +99,10 @@ func (o *Openshift) Generate(dependencies asset.Parents) error { Base64EncodedKubeadminPwHash: base64.StdEncoding.EncodeToString(kubeadminPassword.PasswordHash), } - bindingDiscovery := &tectonic.BindingDiscovery{} - cloudCredsSecret := &tectonic.CloudCredsSecret{} - kubeadminPasswordSecret := &tectonic.KubeadminPasswordSecret{} - roleCloudCredsSecretReader := &tectonic.RoleCloudCredsSecretReader{} + bindingDiscovery := &openshift.BindingDiscovery{} + cloudCredsSecret := &openshift.CloudCredsSecret{} + kubeadminPasswordSecret := &openshift.KubeadminPasswordSecret{} + roleCloudCredsSecretReader := &openshift.RoleCloudCredsSecretReader{} dependencies.Get( bindingDiscovery, cloudCredsSecret, diff --git a/pkg/asset/templates/content/helper.go b/pkg/asset/templates/content/helper.go index 27dd210ae55..4f7cef720ba 100644 --- a/pkg/asset/templates/content/helper.go +++ b/pkg/asset/templates/content/helper.go @@ -9,9 +9,9 @@ import ( const ( // TemplateDir is the target directory for all template assets' files - TemplateDir = "templates" - bootkubeDataDir = "manifests/bootkube/" - tectonicDataDir = "manifests/tectonic/" + TemplateDir = "templates" + bootkubeDataDir = "manifests/bootkube/" + openshiftDataDir = "manifests/openshift/" ) // GetBootkubeTemplate returns the contents of the file in bootkube data dir @@ -19,9 +19,9 @@ func GetBootkubeTemplate(uri string) ([]byte, error) { return getFileContents(path.Join(bootkubeDataDir, uri)) } -// GetTectonicTemplate returns the contents of the file in tectonic data dir -func GetTectonicTemplate(uri string) ([]byte, error) { - return getFileContents(path.Join(tectonicDataDir, uri)) +// GetOpenshiftTemplate returns the contents of the file in openshift data dir +func GetOpenshiftTemplate(uri string) ([]byte, error) { + return getFileContents(path.Join(openshiftDataDir, uri)) } // getFileContents the content of the given URI, assuming that it's a file diff --git a/pkg/asset/templates/content/tectonic/binding-discovery.go b/pkg/asset/templates/content/openshift/binding-discovery.go similarity index 95% rename from pkg/asset/templates/content/tectonic/binding-discovery.go rename to pkg/asset/templates/content/openshift/binding-discovery.go index 7643525f1ec..1a5efcf2ccc 100644 --- a/pkg/asset/templates/content/tectonic/binding-discovery.go +++ b/pkg/asset/templates/content/openshift/binding-discovery.go @@ -1,4 +1,4 @@ -package tectonic +package openshift import ( "os" @@ -33,7 +33,7 @@ func (t *BindingDiscovery) Name() string { // Generate generates the actual files by this asset func (t *BindingDiscovery) Generate(parents asset.Parents) error { t.fileName = bindingDiscoveryFileName - data, err := content.GetTectonicTemplate(t.fileName) + data, err := content.GetOpenshiftTemplate(t.fileName) if err != nil { return err } diff --git a/pkg/asset/templates/content/tectonic/cloud-creds-secret.go b/pkg/asset/templates/content/openshift/cloud-creds-secret.go similarity index 95% rename from pkg/asset/templates/content/tectonic/cloud-creds-secret.go rename to pkg/asset/templates/content/openshift/cloud-creds-secret.go index cb0149228a1..0fde33ccfad 100644 --- a/pkg/asset/templates/content/tectonic/cloud-creds-secret.go +++ b/pkg/asset/templates/content/openshift/cloud-creds-secret.go @@ -1,4 +1,4 @@ -package tectonic +package openshift import ( "os" @@ -33,7 +33,7 @@ func (t *CloudCredsSecret) Name() string { // Generate generates the actual files by this asset func (t *CloudCredsSecret) Generate(parents asset.Parents) error { t.fileName = cloudCredsSecretFileName - data, err := content.GetTectonicTemplate(t.fileName) + data, err := content.GetOpenshiftTemplate(t.fileName) if err != nil { return err } diff --git a/pkg/asset/templates/content/tectonic/kubeadmin-password-secret.go b/pkg/asset/templates/content/openshift/kubeadmin-password-secret.go similarity index 95% rename from pkg/asset/templates/content/tectonic/kubeadmin-password-secret.go rename to pkg/asset/templates/content/openshift/kubeadmin-password-secret.go index 25cb282237c..aeedb196826 100644 --- a/pkg/asset/templates/content/tectonic/kubeadmin-password-secret.go +++ b/pkg/asset/templates/content/openshift/kubeadmin-password-secret.go @@ -1,4 +1,4 @@ -package tectonic +package openshift import ( "os" @@ -33,7 +33,7 @@ func (t *KubeadminPasswordSecret) Name() string { // Generate generates the actual files by this asset func (t *KubeadminPasswordSecret) Generate(parents asset.Parents) error { t.fileName = kubeadminPasswordSecretFileName - data, err := content.GetTectonicTemplate(t.fileName) + data, err := content.GetOpenshiftTemplate(t.fileName) if err != nil { return err } diff --git a/pkg/asset/templates/content/tectonic/role-cloud-creds-secret-reader.go b/pkg/asset/templates/content/openshift/role-cloud-creds-secret-reader.go similarity index 95% rename from pkg/asset/templates/content/tectonic/role-cloud-creds-secret-reader.go rename to pkg/asset/templates/content/openshift/role-cloud-creds-secret-reader.go index e3ccbdcd159..127b0414307 100644 --- a/pkg/asset/templates/content/tectonic/role-cloud-creds-secret-reader.go +++ b/pkg/asset/templates/content/openshift/role-cloud-creds-secret-reader.go @@ -1,4 +1,4 @@ -package tectonic +package openshift import ( "os" @@ -33,7 +33,7 @@ func (t *RoleCloudCredsSecretReader) Name() string { // Generate generates the actual files by this asset func (t *RoleCloudCredsSecretReader) Generate(parents asset.Parents) error { t.fileName = roleCloudCredsSecretReaderFileName - data, err := content.GetTectonicTemplate(t.fileName) + data, err := content.GetOpenshiftTemplate(t.fileName) if err != nil { return err } diff --git a/pkg/asset/templates/templates.go b/pkg/asset/templates/templates.go index 493d59fefb2..27a4f664416 100644 --- a/pkg/asset/templates/templates.go +++ b/pkg/asset/templates/templates.go @@ -4,7 +4,7 @@ package templates import ( "github.com/openshift/installer/pkg/asset" "github.com/openshift/installer/pkg/asset/templates/content/bootkube" - "github.com/openshift/installer/pkg/asset/templates/content/tectonic" + "github.com/openshift/installer/pkg/asset/templates/content/openshift" ) var _ asset.WritableAsset = (*Templates)(nil) @@ -38,10 +38,10 @@ func (m *Templates) Dependencies() []asset.Asset { &bootkube.OpenshiftServiceCertSignerNamespace{}, &bootkube.EtcdServiceKubeSystem{}, &bootkube.HostEtcdServiceKubeSystem{}, - &tectonic.BindingDiscovery{}, - &tectonic.CloudCredsSecret{}, - &tectonic.KubeadminPasswordSecret{}, - &tectonic.RoleCloudCredsSecretReader{}, + &openshift.BindingDiscovery{}, + &openshift.CloudCredsSecret{}, + &openshift.KubeadminPasswordSecret{}, + &openshift.RoleCloudCredsSecretReader{}, } } @@ -63,10 +63,10 @@ func (m *Templates) Generate(dependencies asset.Parents) error { etcdServiceKubeSystem := &bootkube.EtcdServiceKubeSystem{} hostEtcdServiceKubeSystem := &bootkube.HostEtcdServiceKubeSystem{} - bindingDiscovery := &tectonic.BindingDiscovery{} - cloudCredsSecret := &tectonic.CloudCredsSecret{} - kubeadminPasswordSecret := &tectonic.KubeadminPasswordSecret{} - roleCloudCredsSecretReader := &tectonic.RoleCloudCredsSecretReader{} + bindingDiscovery := &openshift.BindingDiscovery{} + cloudCredsSecret := &openshift.CloudCredsSecret{} + kubeadminPasswordSecret := &openshift.KubeadminPasswordSecret{} + roleCloudCredsSecretReader := &openshift.RoleCloudCredsSecretReader{} dependencies.Get( kubeCloudConfig, From 62bb10e0f7cb9daafc7fb1451d73b5a9f402b63a Mon Sep 17 00:00:00 2001 From: staebler Date: Mon, 26 Nov 2018 15:33:37 -0500 Subject: [PATCH 10/13] asset/templates: remove tectonic reference from CVO overrides assets Changes for https://jira.coreos.com/browse/CORS-878 --- pkg/asset/templates/content/bootkube/cvo-overrides.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/asset/templates/content/bootkube/cvo-overrides.go b/pkg/asset/templates/content/bootkube/cvo-overrides.go index 3e29b3ae7fe..f331ba39032 100644 --- a/pkg/asset/templates/content/bootkube/cvo-overrides.go +++ b/pkg/asset/templates/content/bootkube/cvo-overrides.go @@ -14,9 +14,9 @@ const ( var _ asset.WritableAsset = (*CVOOverrides)(nil) -// CVOOverrides is the constant to represent contents of cvo-override.yaml.template file -// This is a gate to prevent CVO from installing these operators which is conflicting -// with already owned resources by tectonic-operators. +// CVOOverrides is an asset that generates the cvo-override.yaml.template file. +// This is a gate to prevent CVO from installing these operators which conflict +// with resources already owned by other operators. // This files can be dropped when the overrides list becomes empty. type CVOOverrides struct { fileName string From 8d8c43783cf615b042172f98529982e1c5d69cf0 Mon Sep 17 00:00:00 2001 From: staebler Date: Mon, 26 Nov 2018 15:36:32 -0500 Subject: [PATCH 11/13] asset/manifests: remove unusued tectonicCloudProvider function Changes for https://jira.coreos.com/browse/CORS-878 --- pkg/asset/manifests/utils.go | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/pkg/asset/manifests/utils.go b/pkg/asset/manifests/utils.go index d277efa1ab6..1b670a8f117 100644 --- a/pkg/asset/manifests/utils.go +++ b/pkg/asset/manifests/utils.go @@ -33,17 +33,6 @@ func configMap(namespace, name string, data genericData) *configurationObject { } } -// Converts a platform to the cloudProvider that k8s understands -func tectonicCloudProvider(platform types.Platform) string { - if platform.AWS != nil { - return "aws" - } - if platform.Libvirt != nil { - return "libvirt" - } - return "" -} - func getAPIServerURL(ic *types.InstallConfig) string { return fmt.Sprintf("https://%s-api.%s:6443", ic.ObjectMeta.Name, ic.BaseDomain) } From 16a5a6e318e8a3b165f9f35058a67fe45921a8e4 Mon Sep 17 00:00:00 2001 From: staebler Date: Mon, 26 Nov 2018 22:29:06 -0500 Subject: [PATCH 12/13] .: remove unused version.bzl file Bazel is no longer used. Changes for https://jira.coreos.com/browse/CORS-878 --- version.bzl | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 version.bzl diff --git a/version.bzl b/version.bzl deleted file mode 100644 index 57182b95e6f..00000000000 --- a/version.bzl +++ /dev/null @@ -1,8 +0,0 @@ -# This variable set the release version. -# -# BEFORE building an official release, please update it -# with the actual release version string. -# -# THIS FILE SHOULD BE AUTOGENERATED BY RELEASE AUTOMATION. - -TECTONIC_VERSION="dev" From 31bd83fb4dee5a2f2d42f9a14f72ccdd4d90d2a1 Mon Sep 17 00:00:00 2001 From: staebler Date: Tue, 27 Nov 2018 11:16:07 -0500 Subject: [PATCH 13/13] docs: remove tectonic references from docs Changes for https://jira.coreos.com/browse/CORS-878 --- docs/design/assetgeneration.md | 2 +- docs/design/resource_dep.svg | 1168 ++++++++++++++++---------------- docs/dev/libvirt-howto.md | 6 +- docs/dev/operators.md | 2 +- 4 files changed, 604 insertions(+), 574 deletions(-) diff --git a/docs/design/assetgeneration.md b/docs/design/assetgeneration.md index aad6ce5934b..b611780c1dc 100644 --- a/docs/design/assetgeneration.md +++ b/docs/design/assetgeneration.md @@ -76,7 +76,7 @@ $ openshift-install create install-config # Generate install-config.yml $ openshift-install create manifests -# Generate manifests/ and tectonic/ dir, also remove install-config.yml +# Generate manifests/ and openshift/ dir, also remove install-config.yml ``` ## Target generation diff --git a/docs/design/resource_dep.svg b/docs/design/resource_dep.svg index 329ede19184..e0c011bd1ed 100644 --- a/docs/design/resource_dep.svg +++ b/docs/design/resource_dep.svg @@ -4,1096 +4,1126 @@ - + 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 + + + +installconfig.InstallConfig->manifests.Ingress + + 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.Tectonic - -manifests.Tectonic +manifests.Openshift + +manifests.Openshift - - -installconfig.InstallConfig->manifests.Tectonic - - + + +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.emailAddress - -installconfig.emailAddress - - - -installconfig.emailAddress->installconfig.InstallConfig - - - - - -installconfig.password - -installconfig.password - - - -installconfig.password->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.clusterName - + installconfig.clusterName->installconfig.InstallConfig - - + + - + installconfig.pullSecret - -installconfig.pullSecret + +installconfig.pullSecret - + installconfig.pullSecret->installconfig.InstallConfig - - + + - + installconfig.platform - -installconfig.platform + +installconfig.platform - + installconfig.platform->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 - + 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->templates.Templates + + + + + +openshift.BindingDiscovery->manifests.Openshift + + - + + +openshift.CloudCredsSecret + +openshift.CloudCredsSecret + + + +openshift.CloudCredsSecret->templates.Templates + + + + + +openshift.CloudCredsSecret->manifests.Openshift + + + + -tectonic.BindingDiscovery - -tectonic.BindingDiscovery +openshift.KubeadminPasswordSecret + +openshift.KubeadminPasswordSecret - + -tectonic.BindingDiscovery->templates.Templates - - +openshift.KubeadminPasswordSecret->templates.Templates + + - - -tectonic.BindingDiscovery->manifests.Tectonic - - + + +openshift.KubeadminPasswordSecret->manifests.Openshift + + - + -tectonic.CloudCredsSecret - -tectonic.CloudCredsSecret +openshift.RoleCloudCredsSecretReader + +openshift.RoleCloudCredsSecretReader - + -tectonic.CloudCredsSecret->templates.Templates - - - - - -tectonic.CloudCredsSecret->manifests.Tectonic - - +openshift.RoleCloudCredsSecretReader->templates.Templates + + - - -tectonic.RoleCloudCredsSecretReader - -tectonic.RoleCloudCredsSecretReader - - - -tectonic.RoleCloudCredsSecretReader->templates.Templates - - - - - -tectonic.RoleCloudCredsSecretReader->manifests.Tectonic - - + + +openshift.RoleCloudCredsSecretReader->manifests.Openshift + + - + Target Manifests - -Target Manifests + +Target Manifests - + manifests.Manifests->Target Manifests - - + + - + manifests.Manifests->bootstrap.Bootstrap - - + + + + + +manifests.Ingress->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.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.Tectonic->Target Manifests - - + + +manifests.Openshift->Target Manifests + + - - -manifests.Tectonic->bootstrap.Bootstrap - - + + +manifests.Openshift->bootstrap.Bootstrap + + - - -manifests.ClusterK8sIO->manifests.Tectonic - - + + +manifests.ClusterK8sIO->manifests.Openshift + + - - -machines.Worker->manifests.Tectonic - - + + +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.Tectonic - - + + +machines.Master->manifests.Openshift + + - + machine.Master->machines.Master - - + + - + machine.Master->Target Ignition Configs - - + + - + machine.Master->cluster.TerraformVariables - - + + + + + +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 - - + + - + 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 - - + + - + cluster.Cluster->Target Cluster - - + + diff --git a/docs/dev/libvirt-howto.md b/docs/dev/libvirt-howto.md index f586d249810..9b0732e6ad4 100644 --- a/docs/dev/libvirt-howto.md +++ b/docs/dev/libvirt-howto.md @@ -194,7 +194,7 @@ This step is optional, but useful for being able to resolve cluster-internal hos For this example: ```sh - echo server=/tt.testing/192.168.126.1 | sudo tee /etc/NetworkManager/dnsmasq.d/tectonic.conf + echo server=/tt.testing/192.168.126.1 | sudo tee /etc/NetworkManager/dnsmasq.d/openshift.conf ``` 3. `systemctl restart NetworkManager` @@ -261,7 +261,7 @@ The bootstrap node, e.g. `test1-bootstrap.tt.testing`, runs the bootstrap proces ```sh ssh core@$OPENSHIFT_INSTALL_CLUSTER_NAME-bootstrap.$OPENSHIFT_INSTALL_BASE_DOMAIN -sudo journalctl -f -u bootkube -u tectonic +sudo journalctl -f -u bootkube -u openshift ``` You'll have to wait for etcd to reach quorum before this makes any progress. @@ -335,7 +335,7 @@ Error: Error applying plan: Depending on your libvirt version you might encounter [a race condition][bugzilla_libvirt_race] leading to an error similar to: ``` -* libvirt_domain.master.0: Error creating libvirt domain: virError(Code=43, Domain=19, Message='Network not found: no network with matching name 'tectonic'') +* libvirt_domain.master.0: Error creating libvirt domain: virError(Code=43, Domain=19, Message='Network not found: no network with matching name 'test1'') ``` This is also being [tracked on the libvirt-terraform-provider][tfprovider_libvirt_race] but is likely not fixable on the client side, which is why you should upgrade libvirt to >=4.5 or a patched version, depending on your environment. diff --git a/docs/dev/operators.md b/docs/dev/operators.md index ff047834877..e85ae2a2946 100644 --- a/docs/dev/operators.md +++ b/docs/dev/operators.md @@ -16,6 +16,6 @@ Such operators need to be directly integrated in the installer's [`manifests` pa Create a new operator asset, and render the Dependencies, Name, Load and Generate functions. The Dependencies might contain InstallConfig as an example. In the Generate function, create the config files as asset contents. For the config/manifest’s actual structure, one can choose to vendor the operator’s github pkg, or, if the configuration structures are fairly simple then just copy the definitions directly and avoid the hassle of vendoring. Finally, return the entire list of configs and manifests in the Generate function. - Template files -In the pkg/asset/manifests/content/tectonic directory, place the templates golang variables. Then modify pkg/asset/manifests/tectonic.go to expand the template. Expand templateData in template.go for filling up the template variables. +In the pkg/asset/manifests/content/openshift directory, place the templates golang variables. Then modify pkg/asset/manifests/openshift.go to expand the template. Expand templateData in template.go for filling up the template variables. [cvo-operators]: https://github.com/openshift/cluster-version-operator/tree/master/docs/dev/operators.md