Add heat template for creating the stack
This stack will be shared by all the tests we'll create. Also added a README. Change-Id: I53e5aa573e462babaa559d5d7c736b6cc04315a7
This commit is contained in:
parent
31a6360210
commit
2468ef5f71
11
README.rst
Normal file
11
README.rst
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
======
|
||||||
|
Tobiko
|
||||||
|
======
|
||||||
|
|
||||||
|
To run pre-upgrade tests:
|
||||||
|
|
||||||
|
tempest run --regex pre
|
||||||
|
|
||||||
|
To run post-upgrade tests:
|
||||||
|
|
||||||
|
tempest run --regex post
|
85
tobiko/tests/scenario/templates/fip.yaml
Normal file
85
tobiko/tests/scenario/templates/fip.yaml
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
heat_template_version: 2013-05-23
|
||||||
|
|
||||||
|
description: |
|
||||||
|
Template to create an instance and check connectivity to it
|
||||||
|
|
||||||
|
parameters:
|
||||||
|
flavor:
|
||||||
|
type: string
|
||||||
|
image:
|
||||||
|
type: string
|
||||||
|
subnet_cidr:
|
||||||
|
type: string
|
||||||
|
default: 190.40.2.0/24
|
||||||
|
public_net:
|
||||||
|
type: string
|
||||||
|
default: public
|
||||||
|
private_net:
|
||||||
|
type: string
|
||||||
|
default: heat-net
|
||||||
|
dns_servers:
|
||||||
|
type: comma_delimited_list
|
||||||
|
default: ["8.8.8.8", "8.8.4.4"]
|
||||||
|
|
||||||
|
resources:
|
||||||
|
sg:
|
||||||
|
type: OS::Neutron::SecurityGroup
|
||||||
|
properties:
|
||||||
|
name: sg
|
||||||
|
description: Security group to allow ICMP and SSH
|
||||||
|
rules:
|
||||||
|
- protocol: icmp
|
||||||
|
- protocol: tcp
|
||||||
|
port_range_min: 22
|
||||||
|
port_range_max: 22
|
||||||
|
|
||||||
|
floating_ip:
|
||||||
|
type: OS::Neutron::FloatingIP
|
||||||
|
properties:
|
||||||
|
floating_network: {get_param: public_net}
|
||||||
|
|
||||||
|
network:
|
||||||
|
type: OS::Neutron::Net
|
||||||
|
|
||||||
|
subnet:
|
||||||
|
type: OS::Neutron::Subnet
|
||||||
|
properties:
|
||||||
|
network: {get_resource: network}
|
||||||
|
ip_version: 4
|
||||||
|
cidr: {get_param: subnet_cidr}
|
||||||
|
dns_nameservers: {get_param: dns_servers}
|
||||||
|
|
||||||
|
router:
|
||||||
|
type: OS::Neutron::Router
|
||||||
|
properties:
|
||||||
|
external_gateway_info:
|
||||||
|
network: {get_param: public_net}
|
||||||
|
|
||||||
|
router_interface:
|
||||||
|
type: OS::Neutron::RouterInterface
|
||||||
|
properties:
|
||||||
|
router: {get_resource: router}
|
||||||
|
subnet: {get_resource: subnet}
|
||||||
|
|
||||||
|
wait_handle:
|
||||||
|
type: OS::Heat::WaitConditionHandle
|
||||||
|
|
||||||
|
server:
|
||||||
|
type: OS::Nova::Server
|
||||||
|
properties:
|
||||||
|
image: {get_param: image}
|
||||||
|
flavor: {get_param: flavor}
|
||||||
|
networks:
|
||||||
|
- subnet: {get_resource: subnet}
|
||||||
|
security_groups:
|
||||||
|
- {get_resource: sg}
|
||||||
|
|
||||||
|
server_floating_ip_assoc:
|
||||||
|
type: OS::Neutron::FloatingIPAssociation
|
||||||
|
properties:
|
||||||
|
floatingip_id: {get_resource: floating_ip}
|
||||||
|
port_id: {get_attr: [server, addresses, {get_resource: network}, 0, port]}
|
||||||
|
|
||||||
|
outputs:
|
||||||
|
server_ip:
|
||||||
|
value: {get_attr: [floating_ip, floating_ip_address]}
|
Loading…
x
Reference in New Issue
Block a user