From d421a430042a77a91ccd7dc794d964baab5f9d9d Mon Sep 17 00:00:00 2001
From: Richard Case RestrictPrivateSubnets indicates that the EKS control plane should only use private subnets. RestrictPrivateSubnets indicates that the EKS control plane should only use private subnets. "AL2_ARM_64" "AL2023_ARM_64_STANDARD" Al2023Arm64 is the AL2023 Arm AMI type. "AL2023_x86_64_STANDARD" Al2023x86_64 is the AL2023 x86-64 AMI type. "AL2_ARM_64" Al2Arm64 is the Arm AMI type. "AL2_x86_64" "AL2_x86_64_GPU" Al2x86_64GPU is the x86-64 GPU AMI type. "AL2023_ARM_64_STANDARD" Al2023Arm64 is the AL2023 Arm AMI type. "AL2023_x86_64_STANDARD" Al2023x86_64 is the AL2023 x86 AMI type.
+
+
+restrictPrivateSubnets
+
+bool
+
+
+
+
+
kubeProxy
@@ -6979,6 +6990,17 @@ VpcCni
+
+
+restrictPrivateSubnets
+
+bool
+
+
+
+
+
-
kubeProxy
@@ -17072,7 +17094,13 @@ int64
Description
+
+
+
+
+
@@ -17081,12 +17109,6 @@ int64
-
-
-
-ManagedMachinePoolCapacityType
@@ -19005,6 +19027,20 @@ default value is ELBProtocolSSL
healthCheck
HealthCheck sets custom health check configuration to the API target group.
+additionalSecurityGroups
elasticIpPool
ElasticIPPool is the configuration to allocate Public IPv4 address (Elastic IP/EIP) from user-defined pool.
+additionalSecurityGroups
PrivateDNSName is the options for the instance hostname.
capacityReservationId
CapacityReservationID specifies the target Capacity Reservation into which the instance should be launched.
+elasticIpPool
ElasticIPPool is the configuration to allocate Public IPv4 address (Elastic IP/EIP) from user-defined pool.
+additionalSecurityGroups
PrivateDNSName is the options for the instance hostname.
capacityReservationId
CapacityReservationID specifies the target Capacity Reservation into which the instance should be launched.
+elasticIpPool
ElasticIPPool is the configuration to allocate Public IPv4 address (Elastic IP/EIP) from user-defined pool.
+additionalSecurityGroups
PrivateDNSName is the options for the instance hostname.
capacityReservationId
CapacityReservationID specifies the target Capacity Reservation into which the instance should be launched.
+healthCheck
HealthCheck sets the optional custom health check configuration to the API target group.
+
ELBScheme defines the scheme of a load balancer.
++(Appears on:AWSMachineSpec, VPCSpec) +
++
ElasticIPPool allows configuring a Elastic IP pool for resources allocating +public IPv4 addresses on public subnets.
+ +Field | +Description | +
---|---|
+publicIpv4Pool + +string + + |
+
+(Optional)
+ PublicIpv4Pool sets a custom Public IPv4 Pool used to create Elastic IP address for resources +created in public IPv4 subnets. Every IPv4 address, Elastic IP, will be allocated from the custom +Public IPv4 pool that you brought to AWS, instead of Amazon-provided pool. The public IPv4 pool +resource ID starts with ‘ipv4pool-ec2’. + |
+
+publicIpv4PoolFallbackOrder + + +PublicIpv4PoolFallbackOrder + + + |
+
+(Optional)
+ PublicIpv4PoolFallBackOrder defines the fallback action when the Public IPv4 Pool has been exhausted, +no more IPv4 address available in the pool. +When set to ‘amazon-pool’, the controller check if the pool has available IPv4 address, when pool has reached the +IPv4 limit, the address will be claimed from Amazon-pool (default). +When set to ‘none’, the controller will fail the Elastic IP allocation when the publicIpv4Pool is exhausted. + |
+
@@ -21977,6 +22157,18 @@ int64 The field will be combined with source security group IDs if specified.
+natGatewaysIPsSource
NatGatewaysIPsSource use the NAT gateways IPs as the source for the ingress rule.
+PublicIPOnLaunch is the option to associate a public IP on instance launch
+capacityReservationId
CapacityReservationID specifies the target Capacity Reservation into which the instance should be launched.
+string
alias)+(Appears on:ElasticIPPool) +
++
PublicIpv4PoolFallbackOrder defines the list of available fallback action when the PublicIpv4Pool is exhausted. +‘none’ let the controllers return failures when the PublicIpv4Pool is exhausted - no more IPv4 available. +‘amazon-pool’ let the controllers to skip the PublicIpv4Pool and use the Amazon pool, the default.
+string
alias)@@ -22993,6 +23207,18 @@ string
Name defines name of S3 Bucket to be created.
+bestEffortDeleteObjects
BestEffortDeleteObjects defines whether access/permission errors during object deletion should be ignored.
+string
alias)+(Appears on:VPCSpec) +
++
SubnetSchemaType specifies how given network should be divided on subnets +in the VPC depending on the number of AZs.
+@@ -23260,6 +23495,49 @@ Tags
Tags is a collection of tags describing the resource.
+zoneType
ZoneType defines the type of the zone where the subnet is created.
+The valid values are availability-zone, local-zone, and wavelength-zone.
+Subnet with zone type availability-zone (regular) is always selected to create cluster +resources, like Load Balancers, NAT Gateways, Contol Plane nodes, etc.
+Subnet with zone type local-zone or wavelength-zone is not eligible to automatically create +regular cluster resources.
+The public subnet in availability-zone or local-zone is associated with regular public +route table with default route entry to a Internet Gateway.
+The public subnet in wavelength-zone is associated with a carrier public +route table with default route entry to a Carrier Gateway.
+The private subnet in the availability-zone is associated with a private route table with +the default route entry to a NAT Gateway created in that zone.
+The private subnet in the local-zone or wavelength-zone is associated with a private route table with +the default route entry re-using the NAT Gateway in the Region (preferred from the +parent zone, the zone type availability-zone in the region, or first table available).
+parentZoneName
ParentZoneName is the zone name where the current subnet’s zone is tied when +the zone is a Local Zone.
+The subnets in Local Zone or Wavelength Zone locations consume the ParentZoneName +to select the correct private route table to egress traffic to the internet.
+unhealthyThresholdCount
-(Appears on:Listener) +(Appears on:AWSLoadBalancerSpec)
-
TargetGroupSpec specifies target group settings for a given listener. -This is created first, and the ARN is then passed to the listener.
+TargetGroupHealthCheckAPISpec defines the optional health check settings for the API target group.
-name - -string - - |
-
- Name of the TargetGroup. Must be unique over the same group of listeners. - |
-
-port + intervalSeconds int64 |
- Port is the exposed port +(Optional) +The approximate amount of time, in seconds, between health checks of an individual +target. |
-protocol + timeoutSeconds - -ELBProtocol - +int64 |
+(Optional)
+ The amount of time, in seconds, during which no response from a target means +a failed health check. |
-vpcId + thresholdCount -string +int64 |
+(Optional)
+ The number of consecutive health check successes required before considering +a target healthy. |
-targetGroupHealthCheck + unhealthyThresholdCount - -TargetGroupHealthCheck - +int64 |
- HealthCheck is the elb health check associated with the load balancer. +(Optional) +The number of consecutive health check failures required before considering +a target unhealthy. |
-(Appears on:NetworkSpec) +(Appears on:AdditionalListenerSpec)
-
VPCSpec configures an AWS VPC.
+TargetGroupHealthCheckAdditionalSpec defines the optional health check settings for the additional target groups.
-id + protocol + +string + + |
+
+(Optional)
+ The protocol to use to health check connect with the target. When not specified the Protocol +will be the same of the listener. + |
+
+port + +string + + |
+
+(Optional)
+ The port the load balancer uses when performing health checks for additional target groups. When +not specified this value will be set for the same of listener port. + |
+
+path + +string + + |
+
+(Optional)
+ The destination for health checks on the targets when using the protocol HTTP or HTTPS, +otherwise the path will be ignored. + |
+
+intervalSeconds + +int64 + + |
+
+(Optional)
+ The approximate amount of time, in seconds, between health checks of an individual +target. + |
+
+timeoutSeconds + +int64 + + |
+
+(Optional)
+ The amount of time, in seconds, during which no response from a target means +a failed health check. + |
+
+thresholdCount + +int64 + + |
+
+(Optional)
+ The number of consecutive health check successes required before considering +a target healthy. + |
+
+unhealthyThresholdCount + +int64 + + |
+
+(Optional)
+ The number of consecutive health check failures required before considering +a target unhealthy. + |
+
+(Appears on:Listener) +
++
TargetGroupSpec specifies target group settings for a given listener. +This is created first, and the ARN is then passed to the listener.
+ +Field | +Description | +
---|---|
+name + +string + + |
+
+ Name of the TargetGroup. Must be unique over the same group of listeners. + |
+
+port + +int64 + + |
+
+ Port is the exposed port + |
+
+protocol + + +ELBProtocol + + + |
++ | +
+vpcId + +string + + |
++ | +
+targetGroupHealthCheck + + +TargetGroupHealthCheck + + + |
+
+ HealthCheck is the elb health check associated with the load balancer. + |
+
+(Appears on:NetworkSpec) +
++
VPCSpec configures an AWS VPC.
+ +Field | +Description | +
---|---|
+id string @@ -23479,6 +23946,22 @@ Mutually exclusive with IPAMPool. | |
+secondaryCidrBlocks + + +[]VpcCidrBlock + + + |
+
+(Optional)
+ SecondaryCidrBlocks are additional CIDR blocks to be associated when the provider creates a managed VPC. +Defaults to none. Mutually exclusive with IPAMPool. This makes sense to use if, for example, you want to use +a separate IP range for pods (e.g. Cilium ENI mode). + |
+
ipamPool @@ -23520,6 +24003,19 @@ string | |
+carrierGatewayId + +string + + |
+
+(Optional)
+ CarrierGatewayID is the id of the internet gateway associated with the VPC, +for carrier network (Wavelength Zones). + |
+
tags @@ -23593,6 +24089,40 @@ For IPv4-only and dual-stack (IPv4 and IPv6) subnets, an instance DNS name can b or the instance ID (resource-name). For IPv6 only subnets, an instance DNS name must be based on the instance ID (resource-name). |
|
+elasticIpPool + + +ElasticIPPool + + + |
+
+(Optional)
+ ElasticIPPool contains specific configuration to allocate Public IPv4 address (Elastic IP) from user-defined pool +brought to AWS for core infrastructure resources, like NAT Gateways and Public Network Load Balancers for +the API Server. + |
+
+subnetSchema + + +SubnetSchemaType + + + |
+
+(Optional)
+ SubnetSchema specifies how CidrBlock should be divided on subnets in the VPC depending on the number of AZs. +PreferPrivate - one private subnet for each AZ plus one other subnet that will be further sub-divided for the public subnets. +PreferPublic - have the reverse logic of PreferPrivate, one public subnet for each AZ plus one other subnet +that will be further sub-divided for the private subnets. +Defaults to PreferPrivate + |
+
VolumeType describes the EBS volume type. See: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-volume-types.html
++(Appears on:VPCSpec) +
++
VpcCidrBlock defines the CIDR block and settings to associate with the managed VPC. Currently, only IPv4 is supported.
+ +Field | +Description | +
---|---|
+ipv4CidrBlock + +string + + |
+
+ IPv4CidrBlock is the IPv4 CIDR block to associate with the managed VPC. + |
+
string
alias)+(Appears on:SubnetSpec) +
++
ZoneType defines listener AWS Availability Zone type.
+string
alias)@@ -23979,6 +24546,20 @@ Volume
nonRootVolumes
Configuration options for the non root storage volumes.
+sshKeyName
"AL2_ARM_64"
"AL2023_ARM_64_STANDARD"
Al2023Arm64 is the AL2023 Arm AMI type.
+"AL2023_x86_64_STANDARD"
Al2023x86_64 is the AL2023 x86-64 AMI type.
+"AL2_ARM_64"
Al2Arm64 is the Arm AMI type.
"AL2_x86_64"
AutoRepair specifies whether health checks should be enabled for machines -in the NodePool. The default is false.
+in the NodePool. The default is true.updateConfig
UpdateConfig specifies update configurations.
++(Appears on:RosaUpdateConfig) +
++
RollingUpdate specifies MaxUnavailable & MaxSurge number of nodes during update.
+ +Field | +Description | +
---|---|
+maxUnavailable + +k8s.io/apimachinery/pkg/util/intstr.IntOrString + + |
+
+(Optional)
+ MaxUnavailable is the maximum number of nodes that can be unavailable during the update. +Value can be an absolute number (ex: 5) or a percentage of desired nodes (ex: 10%). +Absolute number is calculated from percentage by rounding down. +MaxUnavailable can not be 0 if MaxSurge is 0, default is 0. +Both MaxUnavailable & MaxSurge must use the same units (absolute value or percentage). +Example: when MaxUnavailable is set to 30%, old nodes can be deleted down to 70% of +desired nodes immediately when the rolling update starts. Once new nodes +are ready, more old nodes be deleted, followed by provisioning new nodes, +ensuring that the total number of nodes available at all times during the +update is at least 70% of desired nodes. + |
+
+maxSurge + +k8s.io/apimachinery/pkg/util/intstr.IntOrString + + |
+
+(Optional)
+ MaxSurge is the maximum number of nodes that can be provisioned above the desired number of nodes. +Value can be an absolute number (ex: 5) or a percentage of desired nodes (ex: 10%). +Absolute number is calculated from percentage by rounding up. +MaxSurge can not be 0 if MaxUnavailable is 0, default is 1. +Both MaxSurge & MaxUnavailable must use the same units (absolute value or percentage). +Example: when MaxSurge is set to 30%, new nodes can be provisioned immediately +when the rolling update starts, such that the total number of old and new +nodes do not exceed 130% of desired nodes. Once old nodes have been +deleted, new nodes can be provisioned, ensuring that total number of nodes +running at any time during the update is at most 130% of desired nodes. + |
+
@@ -27002,7 +27663,7 @@ bool
AutoRepair specifies whether health checks should be enabled for machines -in the NodePool. The default is false.
+in the NodePool. The default is true.updateConfig
UpdateConfig specifies update configurations.
++(Appears on:RosaMachinePoolSpec) +
++
RosaUpdateConfig specifies update configuration
+ +Field | +Description | +
---|---|
+rollingUpdate + + +RollingUpdate + + + |
+
+(Optional)
+ RollingUpdate specifies MaxUnavailable & MaxSurge number of nodes during update. + |
+
string
alias)diff --git a/docs/book/src/development/amis.md b/docs/book/src/development/amis.md new file mode 100644 index 0000000000..5afea57036 --- /dev/null +++ b/docs/book/src/development/amis.md @@ -0,0 +1,30 @@ +# Publish AMIs + +Publishing new AMIs is currently a manual process but it will be automated in th every near future (see [this issue](https://github.com/kubernetes-sigs/cluster-api-provider-aws/issues/1982) for progress). + +## Pre-reqs + +- You must have admin access to the CNCF AWAS account used for the AMIs (819546954734) + +## Process + +1. Clone [image-builder](https://github.com/kubernetes-sigs/image-builder) +2. Open a terminal +3. Set the AWS environment variables for the AMI account +4. Change directory into `images/capi` +5. Install dependencies by running: + +```shell +make deps-ami +``` + +6. Build the AMIs using: + +```shell +make build-ami-ubuntu-2004 +make build-ami-ubuntu-2204 +make build-ami-ubuntu-2404 +make build-ami-flatcar +make build-ami-rhel-8 +``` +> NOTE: there are some issues with the RHEL based images at present. diff --git a/docs/book/src/topics/images/amis.md b/docs/book/src/topics/images/amis.md index ef7743bff0..b7cc5105d6 100644 --- a/docs/book/src/topics/images/amis.md +++ b/docs/book/src/topics/images/amis.md @@ -1,11 +1,18 @@ # AWS Machine Images for CAPA Clusters CAPA requires a “machine image” containing pre-installed, matching versions of kubeadm and kubelet. -Machine image is either auto-resolved by CAPA to a public AMI that matches the Kubernetes version in `KubeadmControlPlane` or `MachineDeployment` spec, -or an appropriate custom image ID for the Kubernetes version can be set in `AWSMachineTemplate` spec. -[Pre-built public AMIs](built-amis.md) are published by the maintainers regularly for each new Kubernetes version. +## EKS Clusters -[Custom images](custom-amis.md) can be created using [image-builder][image-builder] project. +For an EKS cluster the default behaviour is to retieve the AMI to use from SSM. This is so the recommended Amazon Linux AMI is used (see [here](https://docs.aws.amazon.com/eks/latest/userguide/retrieve-ami-id.html)). + +Instead of using the auto resolved AMIs an appropriate custom image ID for the Kubernetes version can be set in `AWSMachineTemplate` spec. + +## Non-EKS Clusters + +By default the machine image is auto-resolved by CAPA to a public AMI that matches the Kubernetes version in `KubeadmControlPlane` or `MachineDeployment` spec. These AMIs are published in a community owned AWS account. See [pre-built public AMIs](built-amis.md) for details of the CAPA project published images. + +> IMPORTANT: +> The project doesn't recommend using the public AMIs for production use. Instead its recommended that you build your own AMIs for the Kubernetes versions you want to use. The AMI can then be specified in the `AWSMachineTemplate` spec. [Custom images](custom-amis.md) can be created using [image-builder][image-builder] project. [image-builder]: https://github.com/kubernetes-sigs/image-builder diff --git a/docs/book/src/topics/images/built-amis.md b/docs/book/src/topics/images/built-amis.md index aeba64259c..2619c2655e 100644 --- a/docs/book/src/topics/images/built-amis.md +++ b/docs/book/src/topics/images/built-amis.md @@ -1,15 +1,16 @@ # Pre-built Kubernetes AMIs -New AMIs are built whenever a new Kubernetes version is released for each supported OS distribution and then published to supported regions. +New AMIs are built on a best effort basis when a new Kubernetes version is released. for each supported OS distribution and then published to supported regions. -`clusterawsadm ami list` command lists pre-built reference AMIs by Kubernetes version, OS, or AWS region. -See [clusterawsadm ami list](https://cluster-api-aws.sigs.k8s.io/clusterawsadm/clusterawsadm_ami_list.html) for details. +`clusterawsadm ami list` command lists pre-built reference AMIs by Kubernetes version, OS, or AWS region. See [clusterawsadm ami list](https://cluster-api-aws.sigs.k8s.io/clusterawsadm/clusterawsadm_ami_list.html) for details. + +If you are using a version of clusterawsadm prior to v2.6.2 then you will need to explicitly specify the owner-id for the community account: `clusterawsadm ami list --owner-id 819546954734`. > **Note:** These images are not updated for security fixes and it is recommended to always use the latest patch version for the Kubernetes version you want to run. For production environments, it is highly recommended to build and use your own custom images. ## Supported OS Distributions - Amazon Linux 2 (amazon-2) -- Ubuntu (ubuntu-20.04, ubuntu-22.04) +- Ubuntu (ubuntu-20.04, ubuntu-22.04, ubuntu-24.04) - Centos (centos-7) - Flatcar (flatcar-stable) @@ -29,84 +30,3 @@ See [clusterawsadm ami list](https://cluster-api-aws.sigs.k8s.io/clusterawsadm/c - us-east-2 - us-west-1 - us-west-2 - -## Most recent AMIs -