github.com/openshift/installer@v1.4.17/upi/aws/cloudformation/06_cluster_worker_node.yaml (about) 1 AWSTemplateFormatVersion: 2010-09-09 2 Description: Template for OpenShift Cluster Node Launch (EC2 worker instance) 3 4 Parameters: 5 InfrastructureName: 6 AllowedPattern: ^([a-zA-Z][a-zA-Z0-9\-]{0,26})$ 7 MaxLength: 27 8 MinLength: 1 9 ConstraintDescription: Infrastructure name must be alphanumeric, start with a letter, and have a maximum of 27 characters. 10 Description: A short, unique cluster ID used to tag nodes for the kubelet cloud provider. 11 Type: String 12 RhcosAmi: 13 Description: Current Red Hat Enterprise Linux CoreOS AMI to use for bootstrap. 14 Type: AWS::EC2::Image::Id 15 Subnet: 16 Description: The subnets, recommend private, to launch the worker nodes into. 17 Type: AWS::EC2::Subnet::Id 18 WorkerSecurityGroupId: 19 Description: The worker security group ID to associate with worker nodes. 20 Type: AWS::EC2::SecurityGroup::Id 21 IgnitionLocation: 22 Default: https://api-int.$CLUSTER_NAME.$DOMAIN:22623/config/worker 23 Description: Ignition config file location. 24 Type: String 25 CertificateAuthorities: 26 Default: data:text/plain;charset=utf-8;base64,ABC...xYz== 27 Description: Base64 encoded certificate authority string to use. 28 Type: String 29 WorkerInstanceProfileName: 30 Description: IAM profile to associate with worker nodes. 31 Type: String 32 WorkerInstanceType: 33 Default: m5.large 34 Type: String 35 36 Metadata: 37 AWS::CloudFormation::Interface: 38 ParameterGroups: 39 - Label: 40 default: "Cluster Information" 41 Parameters: 42 - InfrastructureName 43 - Label: 44 default: "Host Information" 45 Parameters: 46 - WorkerInstanceType 47 - RhcosAmi 48 - IgnitionLocation 49 - CertificateAuthorities 50 - WorkerSecurityGroupId 51 - WorkerInstanceProfileName 52 - Label: 53 default: "Network Configuration" 54 Parameters: 55 - Subnet 56 ParameterLabels: 57 Subnet: 58 default: "Subnet" 59 InfrastructureName: 60 default: "Infrastructure Name" 61 WorkerInstanceType: 62 default: "Worker Instance Type" 63 WorkerInstanceProfileName: 64 default: "Worker Instance Profile Name" 65 RhcosAmi: 66 default: "Red Hat Enterprise Linux CoreOS AMI ID" 67 IgnitionLocation: 68 default: "Worker Ignition Source" 69 CertificateAuthorities: 70 default: "Ignition CA String" 71 WorkerSecurityGroupId: 72 default: "Worker Security Group ID" 73 74 Resources: 75 Worker0: 76 Type: AWS::EC2::Instance 77 Properties: 78 ImageId: !Ref RhcosAmi 79 BlockDeviceMappings: 80 - DeviceName: /dev/xvda 81 Ebs: 82 VolumeSize: "120" 83 VolumeType: "gp2" 84 IamInstanceProfile: !Ref WorkerInstanceProfileName 85 InstanceType: !Ref WorkerInstanceType 86 NetworkInterfaces: 87 - AssociatePublicIpAddress: "false" 88 DeviceIndex: "0" 89 GroupSet: 90 - !Ref "WorkerSecurityGroupId" 91 SubnetId: !Ref "Subnet" 92 UserData: 93 Fn::Base64: !Sub 94 - '{"ignition":{"config":{"merge":[{"source":"${SOURCE}"}]},"security":{"tls":{"certificateAuthorities":[{"source":"${CA_BUNDLE}"}]}},"version":"3.1.0"}}' 95 - { 96 SOURCE: !Ref IgnitionLocation, 97 CA_BUNDLE: !Ref CertificateAuthorities, 98 } 99 Tags: 100 - Key: !Join ["", ["kubernetes.io/cluster/", !Ref InfrastructureName]] 101 Value: "shared" 102 103 Outputs: 104 PrivateIP: 105 Description: The compute node private IP address. 106 Value: !GetAtt Worker0.PrivateIp