diff --git a/contrib/tectonic-cli-examples/config.yml b/contrib/tectonic-cli-examples/config.yml deleted file mode 100644 index c92e91286e..0000000000 --- a/contrib/tectonic-cli-examples/config.yml +++ /dev/null @@ -1,364 +0,0 @@ -Clusters: - # The name of the cluster. - # If used in a cloud-environment, this will be prepended to `tectonic_base_domain` resulting in the URL to the Tectonic console. - # - # Note: This field MUST be set manually prior to creating the cluster. - # Warning: Special characters in the name like '.' may cause errors on OpenStack platforms due to resource name constraints. - - Name: Example - Platform: AWS - Networking: - # (optional) Configures the network to be used in Tectonic. One of the following values can be used: - # - # - "flannel": enables overlay networking only. This is implemented by flannel using VXLAN. - # - # - "canal": enables overlay networking including network policy. Overlay is implemented by flannel using VXLAN. Network policy is implemented by Calico. - # - # - "calico-ipip": [ALPHA] enables BGP based networking. Routing and network policy is implemented by Calico. Note this has been tested on baremetal installations only. - # - # - "none": disables the installation of any Pod level networking layer provided by Tectonic. By setting this value, users are expected to deploy their own solution to enable network connectivity for Pods and Services. - Type: canal - - MTU: 1234 - - # (optional) This declares the IP range to assign Kubernetes service cluster IPs in CIDR notation. - # The maximum size of this IP range is /12 - # NodeCIDR: 10.3.0.0/16 - - # (optional) This declares the IP range to assign Kubernetes pod IPs in CIDR notation. - # PodCIDR: 10.2.0.0/16 - Masters: - # The number of master nodes to be created. - # This applies only to cloud platforms. - NodeCount: 2 - MachineType: foo - Workers: - # The number of worker nodes to be created. - # This applies only to cloud platforms. - NodeCount: 3 - MachineType: bar - Etcd: - # The number of etcd nodes to be created. - # If set to zero, the count of etcd nodes will be determined automatically. - # - # Note: This is not supported on bare metal. - NodeCount: 3 - MachineType: baz - - # (optional) List of external etcd v3 servers to connect with (hostnames/IPs only). - # Needs to be set if using an external etcd cluster. - # Note: If this variable is defined, the installer will not create self-signed certs. - # To provide a CA certificate to trust the etcd servers, set "tectonic_etcd_ca_cert_path". - # - # Example: `["etcd1", "etcd2", "etcd3"]` - # ExternalServers: - - ExternalTLSMaterials: - # Validity period of the self-signed certificates (in hours). - # Default is 3 years. - # This setting is ignored if user provided certificates are used. - ValidityPeriod: 26280 - - # (optional) The path of the file containing the CA certificate for TLS communication with etcd. - # - # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variable `tectonic_etcd_servers` must also be set. - # EtcdCACertPath: /dev/null - Tectonic: - # The path the pull secret file in JSON format. - # This is known to be a "Docker pull secret" as produced by the docker login [1] command. - # A sample JSON content is shown in [2]. - # You can download the pull secret from your Account overview page at [3]. - # - # [1] https://docs.docker.com/engine/reference/commandline/login/ - # - # [2] https://coreos.com/os/docs/latest/registry-authentication.html#manual-registry-auth-setup - # - # [3] https://account.coreos.com/overview - PullSecretPath: - - # The path to the tectonic licence file. - # You can download the Tectonic license file from your Account overview page at [1]. - # - # [1] https://account.coreos.com/overview - LicensePath: /Users/dspangenberg/.tectonic/tectonic-license.txt - DNS: - # The base DNS domain of the cluster. It must NOT contain a trailing period. Some - # DNS providers will automatically add this if necessary. - # - # Example: `openstack.dev.coreos.systems`. - # - # Note: This field MUST be set manually prior to creating the cluster. - # This applies only to cloud platforms. - # - # [Azure-specific NOTE] - # To use Azure-provided DNS, `tectonic_base_domain` should be set to `""` - # If using DNS records, ensure that `tectonic_base_domain` is set to a properly configured external DNS zone. - # Instructions for configuring delegated domains for Azure DNS can be found here: https://docs.microsoft.com/en-us/azure/dns/dns-delegate-domain-azure-dns - BaseDomain: foo.bar.baz - ContainerLinux: - # (optional) The Container Linux update channel. - # - # Examples: `stable`, `beta`, `alpha` - # tectonic_container_linux_channel = "stable" - Channel: stable - - # The Container Linux version to use. Set to `latest` to select the latest available version for the selected update channel. - # - # Examples: `latest`, `1465.6.0` - Version: latest - Update: - Server: foo.bar - Channel: stable - AppID: 42-42-0 - Console: - AdminEmail: der@admin.com - AdminPassword: foobarbaz - # --- - GovCloud: - Profile: default - AssetsS3BucketName: bla - DNSServerIP: 1234 - - - - - # (optional) Extra AWS tags to be applied to created autoscaling group resources. - # This is a list of maps having the keys `key`, `value` and `propagate_at_launch`. - # - # Example: `[ { key = "foo", value = "bar", propagate_at_launch = true } ]` - # Tectonic: - # AutoScalingGroupExtraTags: - - - - - - AWS: - # (optional) Unique name under which the Amazon S3 bucket will be created. Bucket name must start with a lower case name and is limited to 63 characters. - # The Tectonic Installer uses the bucket to store tectonic assets and kubeconfig. - # If name is not provided the installer will construct the name using "Name", current AWS region and "BaseDomain" - # AssetsS3BucketName: - - # (optional) Extra AWS tags to be applied to created resources. - # - # Example: `{ "key" = "value", "foo" = "bar" }` - # ExtraTags: - - # (optional) If set to true, create private-facing ingress resources (ELB, A-records). - # If set to false, no private-facing ingress resources will be provisioned and all DNS records will be created in the public Route53 zone. - # PrivateEndpoints: true - - # (optional) This declares the AWS credentials profile to use. - # Profile: default - - # (optional) If set to true, create public-facing ingress resources (ELB, A-records). - # If set to false, no public-facing ingress resources will be created. - # PublicEndpoints: true - - # The target AWS region for the cluster. - Region: eu-west-1 - - # Name of an SSH key located within the AWS region. Example: coreos-user. - SSHKey: - - # Block of IP addresses used by the VPC. - # This should not overlap with any other networks, such as a private datacenter connected via Direct Connect. - VPCCIDRBlock: 10.0.0.0/16 - - External: - # (optional) List of subnet IDs within an existing VPC to deploy master nodes into. - # Required to use an existing VPC and the list must match the AZ count. - # - # Example: `["subnet-111111", "subnet-222222", "subnet-333333"]` - # MasterSubnetIDs: - - # (optional) If set, the given Route53 zone ID will be used as the internal (private) zone. - # This zone will be used to create etcd DNS records as well as internal API and internal Ingress records. - # If set, no additional private zone will be created. - # - # Example: `"Z1ILINNUJGTAO1"` - # PrivateZone: - - # (optional) ID of an existing VPC to launch nodes into. - # If unset a new VPC is created. - # - # Example: `vpc-123456` - # VPCID: - - # (optional) List of subnet IDs within an existing VPC to deploy worker nodes into. - # Required to use an existing VPC and the list must match the AZ count. - # - # Example: `["subnet-111111", "subnet-222222", "subnet-333333"]` - # WorkerSubnetIDs: - - Etcd: - # (optional) List of additional security group IDs for etcd nodes. - # - # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: - - # (optional) Name of IAM role to use for the instance profiles of etcd nodes. - # The name is also the last part of a role's ARN. - # - # Example: - # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer - # * Role Name = tectonic-installer - # IAMRoleName: - - # Instance size for the etcd node(s). Example: `t2.medium`. Read the [etcd recommended hardware](https://coreos.com/etcd/docs/latest/op-guide/hardware.html) guide for best performance - EC2Type: t2.medium - - RootVolume: - # The amount of provisioned IOPS for the root block device of etcd nodes. - # Ignored if the volume type is not io1. - IOPS: 100 - - # The size of the volume in gigabytes for the root block device of etcd nodes. - Size: 30 - - # The type of volume for the root block device of etcd nodes. - Type: gp2 - - Master: - # (optional) This configures master availability zones and their corresponding subnet CIDRs directly. - # - # Example: - # `{ eu-west-1a = "10.0.0.0/20", eu-west-1b = "10.0.16.0/20" }` - # CustomSubnets: - - # Instance size for the master node(s). Example: `t2.medium`. - EC2Type: t2.medium - - # (optional) List of additional security group IDs for master nodes. - # - # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: - - # (optional) Name of IAM role to use for the instance profiles of master nodes. - # The name is also the last part of a role's ARN. - # - # Example: - # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer - # * Role Name = tectonic-installer - # IAMRoleName: - - RootVolume: - # The amount of provisioned IOPS for the root block device of master nodes. - # Ignored if the volume type is not io1. - IOPS: 100 - - # The size of the volume in gigabytes for the root block device of master nodes. - Size: 30 - - # The type of volume for the root block device of master nodes. - Type: gp2 - - Worker: - # (optional) This configures worker availability zones and their corresponding subnet CIDRs directly. - # - # Example: `{ eu-west-1a = "10.0.64.0/20", eu-west-1b = "10.0.80.0/20" }` - # CustomSubnets: - - # Instance size for the worker node(s). Example: `t2.medium`. - EC2Type: t2.medium - - # (optional) List of additional security group IDs for worker nodes. - # - # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: - - # (optional) Name of IAM role to use for the instance profiles of worker nodes. - # The name is also the last part of a role's ARN. - # - # Example: - # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer - # * Role Name = tectonic-installer - # IAMRoleName: - - # (optional) List of ELBs to attach all worker instances to. - # This is useful for exposing NodePort services via load-balancers managed separately from the cluster. - # - # Example: - # * `["ingress-nginx"]` - # LoadBalancers: - - RootVolume: - # The amount of provisioned IOPS for the root block device of worker nodes. - # Ignored if the volume type is not io1. - IOPS: 100 - - # The size of the volume in gigabytes for the root block device of worker nodes. - Size: 30 - - # The type of volume for the root block device of worker nodes. - Type: gp2 - - - # (optional) The content of the PEM-encoded CA certificate, used to generate Tectonic Console's server certificate. - # If left blank, a CA certificate will be automatically generated. - # tectonic_ca_cert = "" - - # (optional) The content of the PEM-encoded CA key, used to generate Tectonic Console's server certificate. - # This field is mandatory if `tectonic_ca_cert` is set. - # tectonic_ca_key = "" - - # (optional) The algorithm used to generate tectonic_ca_key. - # The default value is currently recommended. - # This field is mandatory if `tectonic_ca_cert` is set. - # tectonic_ca_key_alg = "RSA" - - # (optional) A list of PEM encoded CA files that will be installed in /etc/ssl/certs on etcd, master, and worker nodes. - # tectonic_custom_ca_pem_list = "" - - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key algorithm. - # tectonic_ddns_key_algorithm = "" - - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key name. - # tectonic_ddns_key_name = "" - - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key secret. - # tectonic_ddns_key_secret = "" - - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server IP/host to register IP addresses to. - # tectonic_ddns_server = "" - - # (optional) DNS prefix used to construct the console and API server endpoints. - # tectonic_dns_name = "" - - # (optional) The path of the file containing the client certificate for TLS communication with etcd. - # - # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variables `tectonic_etcd_servers`, `tectonic_etcd_ca_cert_path`, and `tectonic_etcd_client_key_path` must also be set. - # tectonic_etcd_client_cert_path = "/dev/null" - - # (optional) The path of the file containing the client key for TLS communication with etcd. - # - # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variables `tectonic_etcd_servers`, `tectonic_etcd_ca_cert_path`, and `tectonic_etcd_client_cert_path` must also be set. - # tectonic_etcd_client_key_path = "/dev/null" - - # (optional) HTTP proxy address. - # - # Example: `http://myproxy.example.com` - # tectonic_http_proxy_address = "" - - # (optional) HTTPS proxy address. - # - # Example: `http://myproxy.example.com` - # tectonic_https_proxy_address = "" - - # (optional) Start iscsid.service to enable iscsi volume attachment. - # tectonic_iscsi_enabled = "false" - - # (optional) List of local endpoints that will not use HTTP proxy. - # - # Example: `["127.0.0.1","localhost",".example.com","10.3.0.1"]` - # tectonic_no_proxy = "" diff --git a/examples/tectonic.aws.yaml b/examples/tectonic.aws.yaml index 5273fb5329..fc97f4459e 100644 --- a/examples/tectonic.aws.yaml +++ b/examples/tectonic.aws.yaml @@ -1,27 +1,27 @@ -Clusters: - - AWS: +clusters: + - aws: # (optional) Unique name under which the Amazon S3 bucket will be created. Bucket name must start with a lower case name and is limited to 63 characters. # The Tectonic Installer uses the bucket to store tectonic assets and kubeconfig. - # If name is not provided the installer will construct the name using "Name", current AWS region and "BaseDomain" - # AssetsS3BucketName: + # If name is not provided the installer will construct the name using "name", current AWS region and "baseDomain" + # assetsS3BucketName: # (optional) Extra AWS tags to be applied to created autoscaling group resources. # This is a list of maps having the keys `key`, `value` and `propagate_at_launch`. - # + # # Example: `[ { key = "foo", value = "bar", propagate_at_launch = true } ]` - # AutoScalingGroupExtraTags: + # autoScalingGroupExtraTags: # (optional) AMI override for all nodes. Example: `ami-foobar123`. - # EC2AMIOverride: + # ec2AMIOverride: - Etcd: + etcd: # Instance size for the etcd node(s). Example: `t2.medium`. Read the [etcd recommended hardware](https:#coreos.com/etcd/docs/latest/op-guide/hardware.html) guide for best performance - EC2Type: t2.medium + ec2Type: t2.medium # (optional) List of additional security group IDs for etcd nodes. - # + # # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: + # extraSGIDs: # (optional) Name of IAM role to use for the instance profiles of etcd nodes. # The name is also the last part of a role's ARN. @@ -29,71 +29,71 @@ Clusters: # Example: # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer # * Role Name = tectonic-installer - # IAMRoleName: + # iamRoleName: - RootVolume: + rootVolume: # The amount of provisioned IOPS for the root block device of etcd nodes. # Ignored if the volume type is not io1. - IOPS: 100 + iops: 100 # The size of the volume in gigabytes for the root block device of etcd nodes. - Size: 30 + size: 30 # The type of volume for the root block device of etcd nodes. - Type: gp2 + type: gp2 - External: + external: # (optional) List of subnet IDs within an existing VPC to deploy master nodes into. # Required to use an existing VPC and the list must match the AZ count. # # Example: `["subnet-111111", "subnet-222222", "subnet-333333"]` - # MasterSubnetIDs: + # masterSubnetIDs: # (optional) If set, the given Route53 zone ID will be used as the internal (private) zone. # This zone will be used to create etcd DNS records as well as internal API and internal Ingress records. # If set, no additional private zone will be created. # # Example: `"Z1ILINNUJGTAO1"` - # PrivateZone: + # privateZone: # (optional) ID of an existing VPC to launch nodes into. # If unset a new VPC is created. # # Example: `vpc-123456` - # VPCID: + # vpcID: # (optional) List of subnet IDs within an existing VPC to deploy worker nodes into. # Required to use an existing VPC and the list must match the AZ count. # # Example: `["subnet-111111", "subnet-222222", "subnet-333333"]` - # WorkerSubnetIDs: + # workerSubnetIDs: # (optional) Extra AWS tags to be applied to created resources. # # Example: `{ "key" = "value", "foo" = "bar" }` - # ExtraTags: + # extraTags: # (optional) Name of IAM role to use to access AWS in order to deploy the Tectonic Cluster. # The name is also the full role's ARN. # # Example: # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer - # InstallerRole: + # installerRole: - Master: + master: # (optional) This configures master availability zones and their corresponding subnet CIDRs directly. # # Example: # `{ eu-west-1a = "10.0.0.0/20", eu-west-1b = "10.0.16.0/20" }` - # CustomSubnets: + # customSubnets: # Instance size for the master node(s). Example: `t2.medium`. - EC2Type: t2.medium + ec2Type: t2.medium # (optional) List of additional security group IDs for master nodes. # # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: + # extraSGIDs: # (optional) Name of IAM role to use for the instance profiles of master nodes. # The name is also the last part of a role's ARN. @@ -101,53 +101,53 @@ Clusters: # Example: # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer # * Role Name = tectonic-installer - # IAMRoleName: + # iamRoleName: - RootVolume: + rootVolume: # The amount of provisioned IOPS for the root block device of master nodes. # Ignored if the volume type is not io1. - IOPS: 100 + iops: 100 # The size of the volume in gigabytes for the root block device of master nodes. - Size: 30 + size: 30 # The type of volume for the root block device of master nodes. - Type: gp2 + type: gp2 # (optional) If set to true, create private-facing ingress resources (ELB, A-records). # If set to false, no private-facing ingress resources will be provisioned and all DNS records will be created in the public Route53 zone. - # PrivateEndpoints: true + # privateEndpoints: true # (optional) This declares the AWS credentials profile to use. - # Profile: default + # profile: default # (optional) If set to true, create public-facing ingress resources (ELB, A-records). # If set to false, no public-facing ingress resources will be created. - # PublicEndpoints: true + # publicEndpoints: true # The target AWS region for the cluster. - Region: eu-west-1 + region: eu-west-1 # Name of an SSH key located within the AWS region. Example: coreos-user. - SSHKey: + sshKey: # Block of IP addresses used by the VPC. # This should not overlap with any other networks, such as a private datacenter connected via Direct Connect. - VPCCIDRBlock: 10.0.0.0/16 + vpcCIDRBlock: 10.0.0.0/16 - Worker: + worker: # (optional) This configures worker availability zones and their corresponding subnet CIDRs directly. # # Example: `{ eu-west-1a = "10.0.64.0/20", eu-west-1b = "10.0.80.0/20" }` - # CustomSubnets: + # customSubnets: # Instance size for the worker node(s). Example: `t2.medium`. - EC2Type: t2.medium + ec2Type: t2.medium # (optional) List of additional security group IDs for worker nodes. # # Example: `["sg-51530134", "sg-b253d7cc"]` - # ExtraSGIDs: + # extraSGIDs: # (optional) Name of IAM role to use for the instance profiles of worker nodes. # The name is also the last part of a role's ARN. @@ -155,25 +155,25 @@ Clusters: # Example: # * Role ARN = arn:aws:iam::123456789012:role/tectonic-installer # * Role Name = tectonic-installer - # IAMRoleName: + # iamRoleName: # (optional) List of ELBs to attach all worker instances to. # This is useful for exposing NodePort services via load-balancers managed separately from the cluster. # # Example: # * `["ingress-nginx"]` - # LoadBalancers: + # loadBalancers: - RootVolume: + rootVolume: # The amount of provisioned IOPS for the root block device of worker nodes. # Ignored if the volume type is not io1. - IOPS: 100 + iops: 100 # The size of the volume in gigabytes for the root block device of worker nodes. - Size: 30 + size: 30 # The type of volume for the root block device of worker nodes. - Type: gp2 + type: gp2 # The base DNS domain of the cluster. It must NOT contain a trailing period. Some # DNS providers will automatically add this if necessary. @@ -187,118 +187,128 @@ Clusters: # To use Azure-provided DNS, `BaseDomain` should be set to `""` # If using DNS records, ensure that `BaseDomain` is set to a properly configured external DNS zone. # Instructions for configuring delegated domains for Azure DNS can be found here: https://docs.microsoft.com/en-us/azure/dns/dns-delegate-domain-azure-dns - BaseDomain: + baseDomain: - CA: + ca: # (optional) The content of the PEM-encoded CA certificate, used to generate Tectonic Console's server certificate. # If left blank, a CA certificate will be automatically generated. - # Cert: + # cert: # (optional) The content of the PEM-encoded CA key, used to generate Tectonic Console's server certificate. # This field is mandatory if `ca_cert` is set. - # Key: + # key: # (optional) The algorithm used to generate ca_key. # The default value is currently recommended. # This field is mandatory if `ca_cert` is set. - # KeyAlg: RSA + # keyAlg: RSA - ContainerLinux: + containerLinux: # (optional) The Container Linux update channel. # # Examples: `stable`, `beta`, `alpha` - # Channel: stable + # channel: stable # The Container Linux version to use. Set to `latest` to select the latest available version for the selected update channel. # # Examples: `latest`, `1465.6.0` - Version: latest + version: latest # (optional) A list of PEM encoded CA files that will be installed in /etc/ssl/certs on etcd, master, and worker nodes. - # CustomCAPEMList: - - DDNS: - Key: - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key algorithm. - # Algorithm: + # customCAPEMList: - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key name. - # Name: + ddns: + key: + # (optional) This only applies if you use the modules/dns/ddns module. + # + # Specifies the RFC2136 Dynamic DNS server key algorithm. + # algorithm: - # (optional) This only applies if you use the modules/dns/ddns module. - # - # Specifies the RFC2136 Dynamic DNS server key secret. - # Secret: + # (optional) This only applies if you use the modules/dns/ddns module. + # + # Specifies the RFC2136 Dynamic DNS server key name. + # name: # (optional) This only applies if you use the modules/dns/ddns module. # - # Specifies the RFC2136 Dynamic DNS server IP/host to register IP addresses to. - # Server: + # Specifies the RFC2136 Dynamic DNS server key secret. + # secret: + + # (optional) This only applies if you use the modules/dns/ddns module. + # + # Specifies the RFC2136 Dynamic DNS server IP/host to register IP addresses to. + # server: # (optional) DNS prefix used to construct the console and API server endpoints. - # DNSName: + # dnsName: - Etcd: + etcd: # The number of etcd nodes to be created. # If set to zero, the count of etcd nodes will be determined automatically. # # Note: This is not supported on bare metal. - Count: 0 - - External: + count: 0 + + external: # (optional) The path of the file containing the CA certificate for TLS communication with etcd. # # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variable `Servers` must also be set. - # CACertPath: /dev/null + # If set, the variable `servers` must also be set. + # caCertPath: /dev/null # (optional) The path of the file containing the client certificate for TLS communication with etcd. # # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variables `Servers`, `CACertPath`, and `ClientKeyPath` must also be set. - # ClientCertPath: /dev/null + # If set, the variables `servers`, `caCertPath`, and `clientKeyPath` must also be set. + # clientCertPath: /dev/null # (optional) The path of the file containing the client key for TLS communication with etcd. # # Note: This works only when used in conjunction with an external etcd cluster. - # If set, the variables `servers`, `CACertPath`, and `ClientCertPath` must also be set. - # ClientKeyPath: /dev/null + # If set, the variables `servers`, `caCertPath`, and `clientCertPath` must also be set. + # clientKeyPath: /dev/null # (optional) List of external etcd v3 servers to connect with (hostnames/IPs only). # Needs to be set if using an external etcd cluster. # Note: If this variable is defined, the installer will not create self-signed certs. - # To provide a CA certificate to trust the etcd servers, set "CACertPath". + # To provide a CA certificate to trust the etcd servers, set "caCertPath". # # Example: `["etcd1", "etcd2", "etcd3"]` - # Servers: + # servers: - ISCSI: + iscsi: # (optional) Start iscsid.service to enable iscsi volume attachment. - # Enabled: false + # enabled: false # The path to the tectonic licence file. # You can download the Tectonic license file from your Account overview page at [1]. # # [1] https://account.coreos.com/overview - LicensePath: + licensePath: - Master: + master: # The number of master nodes to be created. # This applies only to cloud platforms. - Count: 1 + count: 1 # The name of the cluster. - # If used in a cloud-environment, this will be prepended to `BaseDomain` resulting in the URL to the Tectonic console. + # If used in a cloud-environment, this will be prepended to `baseDomain` resulting in the URL to the Tectonic console. # # Note: This field MUST be set manually prior to creating the cluster. # Warning: Special characters in the name like '.' may cause errors on OpenStack platforms due to resource name constraints. - Name: + name: + + networking: + # (optional) This declares the MTU used by Calico. + # mtu: + + # (optional) This declares the IP range to assign Kubernetes pod IPs in CIDR notation. + # podCIDR: 10.2.0.0/16 + + # (optional) This declares the IP range to assign Kubernetes service cluster IPs in CIDR notation. + # The maximum size of this IP range is /12 + # serviceCIDR: 10.3.0.0/16 - Networking: # (optional) Configures the network to be used in Tectonic. One of the following values can be used: # # - "flannel": enables overlay networking only. This is implemented by flannel using VXLAN. @@ -308,33 +318,26 @@ Clusters: # - "calico-ipip": [ALPHA] enables BGP based networking. Routing and network policy is implemented by Calico. Note this has been tested on baremetal installations only. # # - "none": disables the installation of any Pod level networking layer provided by Tectonic. By setting this value, users are expected to deploy their own solution to enable network connectivity for Pods and Services. - # Type: canal - - # (optional) This declares the MTU used by Calico. - # MTU: - - # (optional) This declares the IP range to assign Kubernetes service cluster IPs in CIDR notation. - # The maximum size of this IP range is /12 - # ServiceCIDR: 10.3.0.0/16 + # type: canal - # (optional) This declares the IP range to assign Kubernetes pod IPs in CIDR notation. - # PodCIDR: 10.2.0.0/16 + # The platform used for deploying. + platform: AWS - Proxy: + proxy: # (optional) HTTP proxy address. # # Example: `http://myproxy.example.com` - # HTTP: - + # http: + # (optional) HTTPS proxy address. # # Example: `http://myproxy.example.com` - # HTTPS: + # https: # (optional) List of local endpoints that will not use HTTP proxy. # # Example: `["127.0.0.1","localhost",".example.com","10.3.0.1"]` - # No: + # no: # The path the pull secret file in JSON format. # This is known to be a "Docker pull secret" as produced by the docker login [1] command. @@ -346,14 +349,14 @@ Clusters: # [2] https://coreos.com/os/docs/latest/registry-authentication.html#manual-registry-auth-setup # # [3] https://account.coreos.com/overview - PullSecretPath: + pullSecretPath: # Validity period of the self-signed certificates (in hours). # Default is 3 years. # This setting is ignored if user provided certificates are used. - TLSValidityPeriod: 26280 + tlsValidityPeriod: 26280 - Worker: + worker: # The number of worker nodes to be created. # This applies only to cloud platforms. - Count: 3 + count: 3 diff --git a/installer/pkg/config-generator/fixtures/test-aws.yaml b/installer/pkg/config-generator/fixtures/test-aws.yaml index 56271c4496..94bb0dbdf8 100644 --- a/installer/pkg/config-generator/fixtures/test-aws.yaml +++ b/installer/pkg/config-generator/fixtures/test-aws.yaml @@ -1,46 +1,46 @@ -Clusters: - - Name: test - BaseDomain: cluster.com - Platform: AWS - Networking: - Type: canal - MTU: 1480 - PodCIDR: 10.2.0.0/16 - ServiceCIDR: 10.3.0.0/16 - Masters: - Count: 2 - Workers: - Count: 3 - Etcd: - Count: 3 - TLSValidityPeriod: 26280 - PullSecretPath: /path/config.json - LicensePath: /path/tectonic-license.txt - ContainerLinux: - Channel: stable - Version: latest - Admin: - Email: test@coreos.com - Password: asd123 - AWS: - Region: eu-west-1 - SSHKey: tectonic - VPCCIDRBlock: 10.0.0.0/16 - Etcd: - EC2Type: t2.medium - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 - Master: - EC2Type: t2.medium - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 - Worker: - EC2Type: t2.medium - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 +clusters: + - name: test + baseDomain: cluster.com + platform: AWS + networking: + type: canal + mtu: 1480 + podCIDR: 10.2.0.0/16 + serviceCIDR: 10.3.0.0/16 + masters: + count: 2 + workers: + count: 3 + etcd: + count: 3 + tlsValidityPeriod: 26280 + pullSecretPath: /path/config.json + licensePath: /path/tectonic-license.txt + containerLinux: + channel: stable + version: latest + admin: + email: test@coreos.com + password: asd123 + aws: + region: eu-west-1 + sshKey: tectonic + vpcCIDRBlock: 10.0.0.0/16 + etcd: + ec2Type: t2.medium + rootVolume: + iops: 100 + size: 30 + type: gp2 + master: + ec2Type: t2.medium + rootVolume: + iops: 100 + size: 30 + type: gp2 + worker: + ec2Type: t2.medium + rootVolume: + iops: 100 + size: 30 + type: gp2 diff --git a/installer/pkg/config-generator/fixtures/test.yaml b/installer/pkg/config-generator/fixtures/test.yaml index 3624cb3f1a..19d7c94be3 100644 --- a/installer/pkg/config-generator/fixtures/test.yaml +++ b/installer/pkg/config-generator/fixtures/test.yaml @@ -1,6 +1,6 @@ -Clusters: - - Name: test - Platform: AWS - BaseDomain: cluster.com - Etcd: - Count: 3 +clusters: + - name: test + platform: AWS + baseDomain: cluster.com + etcd: + count: 3 diff --git a/installer/pkg/config/aws/config.go b/installer/pkg/config/aws/config.go index 04342659bf..d9602ee52a 100644 --- a/installer/pkg/config/aws/config.go +++ b/installer/pkg/config/aws/config.go @@ -2,19 +2,19 @@ package aws // Config defines the AWS configuraiton for a cluster. type Config struct { - AssetsS3BucketName string `yaml:"AssetsS3BucketName,omitempty"` - AutoScalingGroupExtraTags string `yaml:"AutoScalingGroupExtraTags,omitempty"` - EC2AMIOverride string `yaml:"EC2AMIOverride,omitempty"` - Etcd component `yaml:"Etcd,omitempty"` - External external `yaml:"External,omitempty"` - ExtraTags string `yaml:"ExtraTags,omitempty"` - InstallerRole string `yaml:"InstallerRole,omitempty"` - Master component `yaml:"Master,omitempty"` - PrivateEndpoints bool `yaml:"PrivateEndpoints,omitempty"` - Profile string `yaml:"Profile,omitempty"` - PublicEndpoints bool `yaml:"PublicEndpoints,omitempty"` - Region string `yaml:"Region,omitempty"` - SSHKey string `yaml:"SSHKey,omitempty"` - VPCCIDRBlock string `yaml:"VPCCIDRBlock,omitempty"` - Worker component `yaml:"Worker,omitempty"` + AssetsS3BucketName string `yaml:"assetsS3BucketName,omitempty"` + AutoScalingGroupExtraTags string `yaml:"autoScalingGroupExtraTags,omitempty"` + EC2AMIOverride string `yaml:"ec2AMIOverride,omitempty"` + Etcd component `yaml:"etcd,omitempty"` + External external `yaml:"external,omitempty"` + ExtraTags string `yaml:"extraTags,omitempty"` + InstallerRole string `yaml:"installerRole,omitempty"` + Master component `yaml:"master,omitempty"` + PrivateEndpoints bool `yaml:"privateEndpoints,omitempty"` + Profile string `yaml:"profile,omitempty"` + PublicEndpoints bool `yaml:"publicEndpoints,omitempty"` + Region string `yaml:"region,omitempty"` + SSHKey string `yaml:"sshKey,omitempty"` + VPCCIDRBlock string `yaml:"vpcCIDRBlock,omitempty"` + Worker component `yaml:"worker,omitempty"` } diff --git a/installer/pkg/config/aws/types.go b/installer/pkg/config/aws/types.go index ae3493419c..42cbf91c55 100644 --- a/installer/pkg/config/aws/types.go +++ b/installer/pkg/config/aws/types.go @@ -1,23 +1,23 @@ package aws type component struct { - CustomSubnets string `yaml:"CustomSubnets,omitempty"` - EC2Type string `yaml:"EC2Type,omitempty"` - ExtraSGIDs string `yaml:"ExtraSGIDs,omitempty"` - IAMRoleName string `yaml:"IAMRoleName,omitempty"` - LoadBalancers string `yaml:"LoadBalancers,omitempty"` - RootVolume rootVolume `yaml:"RootVolume,omitempty"` + CustomSubnets string `yaml:"customSubnets,omitempty"` + EC2Type string `yaml:"ec2Type,omitempty"` + ExtraSGIDs string `yaml:"extraSGIDs,omitempty"` + IAMRoleName string `yaml:"iamRoleName,omitempty"` + LoadBalancers string `yaml:"loadBalancers,omitempty"` + RootVolume rootVolume `yaml:"rootVolume,omitempty"` } type external struct { - MasterSubnetIDs string `yaml:"MasterSubnetIDs,omitempty"` - PrivateZone string `yaml:"PrivateZone,omitempty"` - VPCID string `yaml:"VPCIC,omitempty"` - WorkerSubnetIDs string `yaml:"WorkerSubnetIDs,omitempty"` + MasterSubnetIDs string `yaml:"masterSubnetIDs,omitempty"` + PrivateZone string `yaml:"privateZone,omitempty"` + VPCID string `yaml:"vpcID,omitempty"` + WorkerSubnetIDs string `yaml:"workerSubnetIDs,omitempty"` } type rootVolume struct { - IOPS int `yaml:"RootVolumeIOPS,omitempty"` - Size int `yaml:"RootVolumeSize,omitempty"` - Type string `yaml:"RootVolumeType,omitempty"` + IOPS int `yaml:"iops,omitempty"` + Size int `yaml:"size,omitempty"` + Type string `yaml:"type,omitempty"` } diff --git a/installer/pkg/config/azure/config.go b/installer/pkg/config/azure/config.go index c698c9dead..77b9df7327 100644 --- a/installer/pkg/config/azure/config.go +++ b/installer/pkg/config/azure/config.go @@ -2,13 +2,13 @@ package azure // Config defines the Azure configuraiton for a cluster. type Config struct { - CloudEnvironment string `yaml:"CloudEnvironment,omitempty"` - Etcd component `yaml:"Etcd,omitempty"` - External external `yaml:"External,omitempty"` - ExtraTags string `yaml:"ExtraTags,omitempty"` - Master component `yaml:"Master,omitempty"` - PrivateCluster string `yaml:"PrivateCluster,omitempty"` - SSH ssh `yaml:"SSH,omitempty"` - VNetCIDRBlock string `yaml:"VNetCIDRBlock,omitempty"` - Worker component `yaml:"Worker,omitempty"` + CloudEnvironment string `yaml:"cloudEnvironment,omitempty"` + Etcd component `yaml:"etcd,omitempty"` + External external `yaml:"external,omitempty"` + ExtraTags string `yaml:"extraTags,omitempty"` + Master component `yaml:"master,omitempty"` + PrivateCluster string `yaml:"privateCluster,omitempty"` + SSH ssh `yaml:"ssh,omitempty"` + VNetCIDRBlock string `yaml:"vNetCIDRBlock,omitempty"` + Worker component `yaml:"worker,omitempty"` } diff --git a/installer/pkg/config/azure/types.go b/installer/pkg/config/azure/types.go index 662554231c..1ba590fd93 100644 --- a/installer/pkg/config/azure/types.go +++ b/installer/pkg/config/azure/types.go @@ -1,30 +1,30 @@ package azure type component struct { - StorageType string `yaml:"StorageType,omitempty"` - VMSize string `yaml:"VMSize,omitempty"` + StorageType string `yaml:"storageType,omitempty"` + VMSize string `yaml:"vmSize,omitempty"` } type external struct { - DNSZoneID string `yaml:"DNSZoneID,omitempty"` - MasterSubnetID string `yaml:"MasterSubnetID,omitempty"` - NSG nsg `yaml:"NSG,omitempty"` - ResourceGroup string `yaml:"ResourceGroup,omitempty"` - VNetID string `yaml:"VNetID,omitempty"` - WorkerSubnetID string `yaml:"WorkerSubnetID,omitempty"` + DNSZoneID string `yaml:"dnsZoneID,omitempty"` + MasterSubnetID string `yaml:"masterSubnetID,omitempty"` + NSG nsg `yaml:"nsg,omitempty"` + ResourceGroup string `yaml:"resourceGroup,omitempty"` + VNetID string `yaml:"vNetID,omitempty"` + WorkerSubnetID string `yaml:"workerSubnetID,omitempty"` } type network struct { - External string `yaml:"External,omitempty"` - Internal string `yaml:"Internal,omitempty"` + External string `yaml:"external,omitempty"` + Internal string `yaml:"internal,omitempty"` } type nsg struct { - MasterID string `yaml:"MasterID,omitempty"` - WorkerID string `yaml:"WorkerID,omitempty"` + MasterID string `yaml:"masterID,omitempty"` + WorkerID string `yaml:"workerID,omitempty"` } type ssh struct { - Key string `yaml:"Key,omitempty"` - Network network `yaml:"Network,omitempty"` + Key string `yaml:"key,omitempty"` + Network network `yaml:"network,omitempty"` } diff --git a/installer/pkg/config/gcp/config.go b/installer/pkg/config/gcp/config.go index fef8c79f85..f5f14497a4 100644 --- a/installer/pkg/config/gcp/config.go +++ b/installer/pkg/config/gcp/config.go @@ -2,11 +2,11 @@ package gcp // Config defines the GCP configuraiton for a cluster. type Config struct { - ConfigVersion string `yaml:"ConfigVersion,omitempty"` - Etcd component `yaml:"Etcd,omitempty"` - ExtGoogleManagedZoneName string `yaml:"ExtGoogleManagedZoneName,omitempty"` - Master component `yaml:"Master,omitempty"` - Region string `yaml:"Region,omitempty"` - SSHKey string `yaml:"SSHKey,omitempty"` - Worker component `yaml:"Worker,omitempty"` + ConfigVersion string `yaml:"configVersion,omitempty"` + Etcd component `yaml:"etcd,omitempty"` + ExtGoogleManagedZoneName string `yaml:"extGoogleManagedZoneName,omitempty"` + Master component `yaml:"master,omitempty"` + Region string `yaml:"region,omitempty"` + SSHKey string `yaml:"sshKey,omitempty"` + Worker component `yaml:"worker,omitempty"` } diff --git a/installer/pkg/config/gcp/types.go b/installer/pkg/config/gcp/types.go index e0b04a7f65..af58d8b46b 100644 --- a/installer/pkg/config/gcp/types.go +++ b/installer/pkg/config/gcp/types.go @@ -1,7 +1,7 @@ package gcp type component struct { - DiskSize string `yaml:"DiskSize,omitempty"` - DiskType string `yaml:"DiskType,omitempty"` - GCEType string `yaml:"GCEType,omitempty"` + DiskSize string `yaml:"diskSize,omitempty"` + DiskType string `yaml:"diskType,omitempty"` + GCEType string `yaml:"gceType,omitempty"` } diff --git a/installer/pkg/config/govcloud/config.go b/installer/pkg/config/govcloud/config.go index 0bf473d5e8..3572f7949f 100644 --- a/installer/pkg/config/govcloud/config.go +++ b/installer/pkg/config/govcloud/config.go @@ -7,5 +7,5 @@ import ( // Config defines the GovCloud configuraiton for a cluster. type Config struct { AWS aws.Config `yaml:",inline"` - DNSServerIP string `yaml:"DNSServerIP,omitempty"` + DNSServerIP string `yaml:"dnsServerIP,omitempty"` } diff --git a/installer/pkg/config/metal/config.go b/installer/pkg/config/metal/config.go index 362588c79e..27263309a2 100644 --- a/installer/pkg/config/metal/config.go +++ b/installer/pkg/config/metal/config.go @@ -2,10 +2,10 @@ package metal // Config defines the Metal configuraiton for a cluster. type Config struct { - CalicoMTU string `yaml:"CalicoMTU,omitempty"` - Controller component `yaml:"Controller,omitempty"` - IngressDomain string `yaml:"IngressDomain,omitempty"` - Matchbox matchbox `yaml:"Matchbox,omitempty"` - SSHAuthorizedKey string `yaml:"SSHAuthorizedKey,omitempty"` - Worker component `yaml:"Worker,omitempty"` + CalicoMTU string `yaml:"calicoMTU,omitempty"` + Controller component `yaml:"controller,omitempty"` + IngressDomain string `yaml:"ingressDomain,omitempty"` + Matchbox matchbox `yaml:"matchbox,omitempty"` + SSHAuthorizedKey string `yaml:"sshAuthorizedKey,omitempty"` + Worker component `yaml:"worker,omitempty"` } diff --git a/installer/pkg/config/metal/types.go b/installer/pkg/config/metal/types.go index 93cc144867..b581869733 100644 --- a/installer/pkg/config/metal/types.go +++ b/installer/pkg/config/metal/types.go @@ -1,20 +1,20 @@ package metal type client struct { - Cert string `yaml:"Cert,omitempty"` - Key string `yaml:"Key,omitempty"` + Cert string `yaml:"cert,omitempty"` + Key string `yaml:"key,omitempty"` } type component struct { - Domain string `yaml:"Domain,omitempty"` - Domains string `yaml:"Domains,omitempty"` - MACs string `yaml:"MACs,omitempty"` - Names string `yaml:"Names,omitempty"` + Domain string `yaml:"domain,omitempty"` + Domains string `yaml:"domains,omitempty"` + MACs string `yaml:"macs,omitempty"` + Names string `yaml:"names,omitempty"` } type matchbox struct { - CA string `yaml:"CA,omitempty"` - Client client `yaml:"Client,omitempty"` - HTTPURL string `yaml:"HTTPURL,omitempty"` - RPCEndpoint string `yaml:"RPCEndpoint,omitempty"` + CA string `yaml:"ca,omitempty"` + Client client `yaml:"client,omitempty"` + HTTPURL string `yaml:"httpURL,omitempty"` + RPCEndpoint string `yaml:"rpcEndpoint,omitempty"` } diff --git a/installer/pkg/config/openstack/config.go b/installer/pkg/config/openstack/config.go index 5f826a98c9..7dfae190b6 100644 --- a/installer/pkg/config/openstack/config.go +++ b/installer/pkg/config/openstack/config.go @@ -2,14 +2,14 @@ package openstack // Config defines the OpenStack configuraiton for a cluster. type Config struct { - DisableFloatingIP string `yaml:"DisableFloatingIP,omitempty"` - DNSNameservers string `yaml:"DNSNameservers,omitempty"` - EtcdFlavor flavor `yaml:"EtcdFlavor,omitempty"` - ExternalGatewayID string `yaml:"ExternalGatewayID,omitempty"` - FloatingIPPool string `yaml:"FloatingIPPool,omitempty"` - Image flavor `yaml:"Image,omitempty"` - LBProvider string `yaml:"LBProvider,omitempty"` - MasterFlavor flavor `yaml:"MasterFlavor,omitempty"` - SubnetCIDR string `yaml:"SubnetCIDR,omitempty"` - WorkerFlavor flavor `yaml:"WorkerFlavor,omitempty"` + DisableFloatingIP string `yaml:"disableFloatingIP,omitempty"` + DNSNameservers string `yaml:"dnsNameservers,omitempty"` + EtcdFlavor flavor `yaml:"etcdFlavor,omitempty"` + ExternalGatewayID string `yaml:"externalGatewayID,omitempty"` + FloatingIPPool string `yaml:"floatingIPPool,omitempty"` + Image flavor `yaml:"image,omitempty"` + LBProvider string `yaml:"lbProvider,omitempty"` + MasterFlavor flavor `yaml:"masterFlavor,omitempty"` + SubnetCIDR string `yaml:"subnetCIDR,omitempty"` + WorkerFlavor flavor `yaml:"workerFlavor,omitempty"` } diff --git a/installer/pkg/config/openstack/types.go b/installer/pkg/config/openstack/types.go index da582ea699..601569a891 100644 --- a/installer/pkg/config/openstack/types.go +++ b/installer/pkg/config/openstack/types.go @@ -1,6 +1,6 @@ package openstack type flavor struct { - ID string `yaml:"ID,omitempty"` - Name string `yaml:"Name,omitempty"` + ID string `yaml:"id,omitempty"` + Name string `yaml:"name,omitempty"` } diff --git a/installer/pkg/config/types.go b/installer/pkg/config/types.go index de1055b423..4f4c96065b 100644 --- a/installer/pkg/config/types.go +++ b/installer/pkg/config/types.go @@ -11,99 +11,99 @@ import ( ) type admin struct { - Email string `yaml:"Email"` - Password string `yaml:"Password"` + Email string `yaml:"email"` + Password string `yaml:"password"` } type ca struct { - Cert string `yaml:"Cert"` - Key string `yaml:"Key"` - KeyAlg string `yaml:"KeyAlg"` + Cert string `yaml:"cert"` + Key string `yaml:"key"` + KeyAlg string `yaml:"keyAlg"` } // Cluster defines the config for a cluster. type Cluster struct { - AWS aws.Config `yaml:"AWS,omitempty"` - Admin admin `yaml:"Admin"` - Azure azure.Config `yaml:"Azure,omitempty"` - BaseDomain string `yaml:"BaseDomain"` - CA ca `yaml:"CA"` - ContainerLinux containerLinux `yaml:"ContainerLinux"` - CustomCAPEMList string `yaml:"CustomCAPEMList"` - DDNS ddns `yaml:"DDNS"` - DNSName string `yaml:"DNSName"` - Etcd etcd `yaml:"Etcd"` - GCP gcp.Config `yaml:"GCP,omitempty"` - GovCloud govcloud.Config `yaml:"GovCloud,omitempty"` - ISCSI iscsi `yaml:"ISCSI"` - LicensePath string `yaml:"LicensePath"` - Master master `yaml:"Master"` - Metal metal.Config `yaml:"Metal,omitempty"` - Name string `yaml:"Name"` - Networking networking `yaml:"Networking"` - OpenStack openstack.Config `yaml:"OpenStack,omitempty"` - Platform string `yaml:"Platform"` - Proxy proxy `yaml:"Proxy"` - PullSecretPath string `yaml:"PullSecretPath"` - TLSValidityPeriod int `yaml:"TLSValidityPeriod"` - VMware vmware.Config `yaml:"VMware,omitempty"` - Worker worker `yaml:"Worker"` + AWS aws.Config `yaml:"aws,omitempty"` + Admin admin `yaml:"admin"` + Azure azure.Config `yaml:"azure,omitempty"` + BaseDomain string `yaml:"baseDomain"` + CA ca `yaml:"ca"` + ContainerLinux containerLinux `yaml:"containerLinux"` + CustomCAPEMList string `yaml:"customCAPEMList"` + DDNS ddns `yaml:"ddns"` + DNSName string `yaml:"dnsName"` + Etcd etcd `yaml:"etcd"` + GCP gcp.Config `yaml:"gcp,omitempty"` + GovCloud govcloud.Config `yaml:"govcloud,omitempty"` + ISCSI iscsi `yaml:"iscsi"` + LicensePath string `yaml:"licensePath"` + Master master `yaml:"master"` + Metal metal.Config `yaml:"metal,omitempty"` + Name string `yaml:"name"` + Networking networking `yaml:"networking"` + OpenStack openstack.Config `yaml:"openstack,omitempty"` + Platform string `yaml:"platform"` + Proxy proxy `yaml:"proxy"` + PullSecretPath string `yaml:"pullSecretPath"` + TLSValidityPeriod int `yaml:"tlsValidityPeriod"` + VMware vmware.Config `yaml:"vmware,omitempty"` + Worker worker `yaml:"worker"` } // Config defines the top level config for a configuration file. type Config struct { - Clusters []Cluster `yaml:"Clusters"` + Clusters []Cluster `yaml:"clusters"` } type containerLinux struct { - Channel string `yaml:"Channel"` - Version string `yaml:"Version"` + Channel string `yaml:"channel"` + Version string `yaml:"version"` } type ddns struct { - Key ddnsKey `yaml:"Key"` - Server string `yaml:"Secret"` + Key ddnsKey `yaml:"key"` + Server string `yaml:"secret"` } type ddnsKey struct { - Algorithm string `yaml:"Algorithm"` - Name string `yaml:"Name"` - Secret string `yaml:"Secret"` + Algorithm string `yaml:"algorithm"` + Name string `yaml:"name"` + Secret string `yaml:"secret"` } type etcd struct { - Count int `yaml:"Count"` - External etcdExternal `yaml:"External"` + Count int `yaml:"count"` + External etcdExternal `yaml:"external"` } type etcdExternal struct { - CACertPath string `yaml:"CACertPath"` - ClientCertPath string `yaml:"ClientCertPath"` - ClientKeyPath string `yaml:"ClientKeyPath"` - Servers []string `yaml:"Servers"` + CACertPath string `yaml:"caCertPath"` + ClientCertPath string `yaml:"clientCertPath"` + ClientKeyPath string `yaml:"clientKeyPath"` + Servers []string `yaml:"servers"` } type iscsi struct { - Enabled bool `yaml:"Enabled"` + Enabled bool `yaml:"enabled"` } type master struct { - Count int `yaml:"Count"` + Count int `yaml:"count"` } type networking struct { - Type string `yaml:"Type"` - MTU string `yaml:"MTU"` - ServiceCIDR string `yaml:"ServiceCIDR"` - PodCIDR string `yaml:"PodCIDR"` + Type string `yaml:"type"` + MTU string `yaml:"mtu"` + ServiceCIDR string `yaml:"serviceCIDR"` + PodCIDR string `yaml:"podCIDR"` } type proxy struct { - HTTP string `yaml:"HTTP"` - HTTPS string `yaml:"HTTPS"` - No string `yaml:"No"` + HTTP string `yaml:"http"` + HTTPS string `yaml:"https"` + No string `yaml:"no"` } type worker struct { - Count int `yaml:"Count"` + Count int `yaml:"count"` } diff --git a/installer/pkg/config/vmware/config.go b/installer/pkg/config/vmware/config.go index d038fcb533..df953ca40f 100644 --- a/installer/pkg/config/vmware/config.go +++ b/installer/pkg/config/vmware/config.go @@ -2,16 +2,16 @@ package vmware // Config defines the VMware configuraiton for a cluster. type Config struct { - ControllerDomain string `yaml:"ControllerDomain,omitempty"` - Etcd component `yaml:"Etcd,omitempty"` - Folder string `yaml:"Folder,omitempty"` - IngressDomain string `yaml:"IngressDomain,omitempty"` - Master component `yaml:"Master,omitempty"` - NodeDNS string `yaml:"NodeDNS,omitempty"` - Server string `yaml:"Server,omitempty"` - SSH ssh `yaml:"SSH,omitempty"` - SSLSelfSigned string `yaml:"SSLSelfsigned,omitempty"` - Type string `yaml:"Type,omitempty"` - VM vm `yaml:"VM,omitempty"` - Worker component `yaml:"Worker,omitempty"` + ControllerDomain string `yaml:"controllerDomain,omitempty"` + Etcd component `yaml:"etcd,omitempty"` + Folder string `yaml:"folder,omitempty"` + IngressDomain string `yaml:"ingressDomain,omitempty"` + Master component `yaml:"master,omitempty"` + NodeDNS string `yaml:"nodeDNS,omitempty"` + Server string `yaml:"server,omitempty"` + SSH ssh `yaml:"ssh,omitempty"` + SSLSelfSigned string `yaml:"sslSelfsigned,omitempty"` + Type string `yaml:"type,omitempty"` + VM vm `yaml:"vm,omitempty"` + Worker component `yaml:"worker,omitempty"` } diff --git a/installer/pkg/config/vmware/types.go b/installer/pkg/config/vmware/types.go index fbc01a766b..3c364bb9b3 100644 --- a/installer/pkg/config/vmware/types.go +++ b/installer/pkg/config/vmware/types.go @@ -1,24 +1,24 @@ package vmware type component struct { - Clusters string `yaml:"Clusters,omitempty"` - Datacenters string `yaml:"Datacenters,omitempty"` - Datastores string `yaml:"Datastores,omitempty"` - Gateways string `yaml:"Gateways,omitempty"` - Hostnames string `yaml:"Hostnames,omitempty"` - IP string `yaml:"IP,omitempty"` - Memory string `yaml:"Memory,omitempty"` - Networks string `yaml:"Networks,omitempty"` - ResourcePool string `yaml:"ResourcePool,omitempty"` - VCPU string `yaml:"VCPU,omitempty"` + Clusters string `yaml:"clusters,omitempty"` + Datacenters string `yaml:"datacenters,omitempty"` + Datastores string `yaml:"datastores,omitempty"` + Gateways string `yaml:"gateways,omitempty"` + Hostnames string `yaml:"hostnames,omitempty"` + IP string `yaml:"ip,omitempty"` + Memory string `yaml:"memory,omitempty"` + Networks string `yaml:"networks,omitempty"` + ResourcePool string `yaml:"resourcePool,omitempty"` + VCPU string `yaml:"vCPU,omitempty"` } type ssh struct { - AuthorizedKey string `yaml:"AuthorizedKey,omitempty"` - PrivateKeyPath string `yaml:"PrivateKeyPath,omitempty"` + AuthorizedKey string `yaml:"authorizedKey,omitempty"` + PrivateKeyPath string `yaml:"privateKeyPath,omitempty"` } type vm struct { - Template string `yaml:"Template,omitempty"` - TemplateFolder string `yaml:"TemplateFolder,omitempty"` + Template string `yaml:"template,omitempty"` + TemplateFolder string `yaml:"templateFolder,omitempty"` } diff --git a/tests/rspec/lib/config_file.rb b/tests/rspec/lib/config_file.rb index b7448a2aa2..3a46ffcac9 100644 --- a/tests/rspec/lib/config_file.rb +++ b/tests/rspec/lib/config_file.rb @@ -18,7 +18,7 @@ def data end def networking - data['Clusters'][0]['Networking']['Type'] + data['clusters'][0]['networking']['type'] end def node_count @@ -26,79 +26,79 @@ def node_count end def master_count - data['Clusters'][0]['Master']['Count'] + data['clusters'][0]['master']['count'] end def worker_count - data['Clusters'][0]['Worker']['Count'] + data['clusters'][0]['worker']['count'] end def etcd_count - data['Clusters'][0]['Etcd']['Count'] + data['clusters'][0]['etcd']['count'] end def add_worker_node(node_count) new_data = data - new_data['Clusters'][0]['Worker']['Count'] = node_count + new_data['clusters'][0]['worker']['count'] = node_count save(new_data) end def change_cluster_name(cluster_name) new_data = data - new_data['Clusters'][0]['Name'] = cluster_name + new_data['clusters'][0]['name'] = cluster_name save(new_data) end def cluster_name - data['Clusters'][0]['Name'] + data['clusters'][0]['name'] end def change_aws_region(region) new_data = data - new_data['Clusters'][0]['AWS']['Region'] = region + new_data['clusters'][0]['aws']['region'] = region save(new_data) end def region(platform) - data['Clusters'][0][platform.upcase]['Region'] + data['clusters'][0][platform]['region'] end def change_license(license_path) new_data = data - new_data['Clusters'][0]['LicensePath'] = license_path + new_data['clusters'][0]['licensePath'] = license_path save(new_data) end def change_pull_secret(pull_secret_path) new_data = data - new_data['Clusters'][0]['PullSecretPath'] = pull_secret_path + new_data['clusters'][0]['pullSecretPath'] = pull_secret_path save(new_data) end def change_base_domain(base_domain) new_data = data - new_data['Clusters'][0]['BaseDomain'] = base_domain + new_data['clusters'][0]['baseDomain'] = base_domain save(new_data) end def license - data['Clusters'][0]['LicensePath'] + data['clusters'][0]['licensePath'] end def pull_secret - data['Clusters'][0]['PullSecretPath'] + data['clusters'][0]['pullSecretPath'] end def change_admin_credentials(admin_email, admin_passwd) new_data = data - new_data['Clusters'][0]['Admin']['Email'] = admin_email - new_data['Clusters'][0]['Admin']['Password'] = admin_passwd + new_data['clusters'][0]['admin']['email'] = admin_email + new_data['clusters'][0]['admin']['password'] = admin_passwd save(new_data) end def admin_credentials - admin_email = data['Clusters'][0]['Admin']['Email'] - admin_passwd = data['Clusters'][0]['Admin']['Password'] + admin_email = data['clusters'][0]['admin']['email'] + admin_passwd = data['clusters'][0]['admin']['password'] [admin_email, admin_passwd] end @@ -110,13 +110,13 @@ def prefix def change_ssh_key(platform, ssh_key) new_data = data - new_data['Clusters'][0][platform.upcase]['SSHKey'] = ssh_key + new_data['clusters'][0][platform]['sshKey'] = ssh_key save(new_data) end def platform PLATFORMS.each do |plat| - return plat if data['Clusters'][0]['Platform'].downcase.eql?(plat) + return plat if data['clusters'][0]['platform'].downcase.eql?(plat) end end diff --git a/tests/smoke/aws/vars/aws.basic.yaml b/tests/smoke/aws/vars/aws.basic.yaml index 0af36490ed..457a177b54 100644 --- a/tests/smoke/aws/vars/aws.basic.yaml +++ b/tests/smoke/aws/vars/aws.basic.yaml @@ -1,50 +1,46 @@ -Clusters: - - Name: aws-basic - BaseDomain: tectonic-ci.de - Platform: AWS - Networking: - Type: canal - MTU: 1480 - PodCIDR: 10.2.0.0/16 - ServiceCIDR: 10.3.0.0/16 - Master: - Count: 2 - Worker: - Count: 3 - Etcd: - Count: 3 - TLSValidityPeriod: 26280 - PullSecretPath: null - LicensePath: null - ContainerLinux: - Channel: beta - Version: latest - Update: - Server: foo.bar - Channel: stable - AppID: 42-42-0 - Admin: - Email: null - Password: null - AWS: - Region: null - SSHKey: null - VPCCIDRBlock: 10.0.0.0/16 - Etcd: - EC2Type: m4.large - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 - Master: - EC2Type: m4.large - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 - Worker: - EC2Type: m4.large - RootVolume: - IOPS: 100 - Size: 30 - Type: gp2 +clusters: + - admin: + email: null + password: null + aws: + etcd: + ec2Type: m4.large + rootVolume: + iops: 100 + size: 30 + type: gp2 + master: + ec2Type: m4.large + rootVolume: + iops: 100 + size: 30 + type: gp2 + region: null + sshKey: null + vpcCIDRBlock: 10.0.0.0/16 + worker: + ec2Type: m4.large + rootVolume: + iops: 100 + size: 30 + type: gp2 + baseDomain: tectonic-ci.de + containerLinux: + channel: beta + version: latest + etcd: + count: 3 + licensePath: + master: + count: 2 + name: aws-basic + networking: + mtu: 1480 + podCIDR: 10.2.0.0/16 + serviceCIDR: 10.3.0.0/16 + type: canal + platform: AWS + pullSecretPath: + tlsValidityPeriod: 26280 + worker: + count: 3