146 lines
3.4 KiB
YAML
146 lines
3.4 KiB
YAML
Description: Create a bare metal test environment undercloud host to run test environment workers.
|
|
HeatTemplateFormatVersion: '2012-12-12'
|
|
Parameters:
|
|
AuthTenant:
|
|
Description: Overcloud Auth Tenant.
|
|
Type: String
|
|
Default: 'openstack-nodepool'
|
|
AuthUrl:
|
|
Description: Overcloud Keystone.
|
|
Type: String
|
|
AuthUser:
|
|
Description: Overcloud Auth User.
|
|
Type: String
|
|
Default: 'tripleo-ci'
|
|
NoEcho: true
|
|
AuthPassword:
|
|
Description: User password.
|
|
Type: String
|
|
NoEcho: true
|
|
CPUPerEnv:
|
|
Default: 3
|
|
Description: CPU's to require per testenv
|
|
Type: String
|
|
DiskPerEnv:
|
|
Default: 60
|
|
Description: Disk space to require per testenv
|
|
Type: String
|
|
GearmanHost:
|
|
Description: Gearman server host.
|
|
Type: String
|
|
GearmanPort:
|
|
Default: 4730
|
|
Description: Gearman server port.
|
|
Type: String
|
|
KeyName:
|
|
Default: default
|
|
Description: Name of an existing EC2 KeyPair to enable SSH access
|
|
Type: String
|
|
Hosts:
|
|
Default: ''
|
|
Description: A string to append to /etc/hosts
|
|
Type: String
|
|
MemPerEnv:
|
|
Default: 10
|
|
Description: RAM to require per testenv
|
|
Type: String
|
|
NetworkName:
|
|
Description: Name of the Neutron network to allocate ports on.
|
|
Type: String
|
|
Flavor:
|
|
Default: baremetal_full
|
|
Description: Flavor to request when deploying.
|
|
Type: String
|
|
PublicInterface:
|
|
Default: eth0
|
|
Description: Network interface to make into a bridge (for seed vm connectivity)
|
|
Type: String
|
|
NtpServer:
|
|
Type: String
|
|
Default: ''
|
|
testenvImage:
|
|
Default: testenv-worker
|
|
Type: String
|
|
Resources:
|
|
AccessPolicy:
|
|
Properties:
|
|
AllowedResources:
|
|
- testenv0
|
|
Type: OS::Heat::AccessPolicy
|
|
Key:
|
|
Properties:
|
|
UserName:
|
|
Ref: User
|
|
Type: AWS::IAM::AccessKey
|
|
User:
|
|
Properties:
|
|
Policies:
|
|
- Ref: AccessPolicy
|
|
Type: AWS::IAM::User
|
|
testenv0CompletionCondition:
|
|
DependsOn: testenv0
|
|
Properties:
|
|
Count: '1'
|
|
Handle:
|
|
Ref: testenv0CompletionHandle
|
|
Timeout: '900'
|
|
Type: AWS::CloudFormation::WaitCondition
|
|
testenv0CompletionHandle:
|
|
Type: AWS::CloudFormation::WaitConditionHandle
|
|
testenv0:
|
|
Metadata:
|
|
completion-handle:
|
|
Ref: testenv0CompletionHandle
|
|
os-collect-config:
|
|
cfn:
|
|
access_key_id:
|
|
Ref: Key
|
|
path: testenv0.Metadata
|
|
secret_access_key:
|
|
Fn::GetAtt:
|
|
- Key
|
|
- SecretAccessKey
|
|
stack_name:
|
|
Ref: AWS::StackName
|
|
gearman-worker:
|
|
host:
|
|
Ref: GearmanHost
|
|
port:
|
|
Ref: GearmanPort
|
|
mem-per-env:
|
|
Ref: MemPerEnv
|
|
cpu-per-env:
|
|
Ref: CPUPerEnv
|
|
disk-per-env:
|
|
Ref: DiskPerEnv
|
|
auth_user:
|
|
Ref: AuthUser
|
|
auth_tenant:
|
|
Ref: AuthTenant
|
|
auth_url:
|
|
Ref: AuthUrl
|
|
auth_passwd:
|
|
Ref: AuthPassword
|
|
network_name:
|
|
Ref: NetworkName
|
|
neutron:
|
|
ovs:
|
|
public_interface:
|
|
Ref: PublicInterface
|
|
physical_bridge: br-ctlplane
|
|
hosts:
|
|
Ref: Hosts
|
|
ntp:
|
|
servers:
|
|
- {server: {Ref: NtpServer}, fudge: "stratum 0"}
|
|
Properties:
|
|
flavor:
|
|
Ref: Flavor
|
|
image:
|
|
Ref: testenvImage
|
|
key_name:
|
|
Ref: KeyName
|
|
networks:
|
|
- network: ctlplane
|
|
Type: OS::Nova::Server
|