blob: 969f84ce56cc9a7ad6eaa36f1b9c1ccfee01949b [file] [log] [blame]
Scott Baker50421662016-06-27 22:09:48 -07001tosca_definitions_version: tosca_simple_yaml_1_0
2
3# Note:
4# assumes mydeployment.yaml has already been run, and the following exist:
5# MyDeployment
6# mysite
7# padmin@vicci.org
8# Public Shared IPv4
9# assumes the following have been created and filled with appropriate data:
10# /root/setup/admin_openrc
11# /root/setup/flat_net_name
12# /root/setup/padmin_public_key
13
14description: >
15 * Adds OpenCloud Sites, Deployments, and Controllers.
16
17imports:
18 - custom_types/xos.yaml
19
20topology_template:
21 node_templates:
22 trusty-server-multi-nic:
23 type: tosca.nodes.Image
24 properties:
25 disk_format: QCOW2
26 container_format: BARE
27
28 MyDeployment:
29 type: tosca.nodes.Deployment
30 properties:
31 no-create: True
32 no-delete: True
33 requirements:
34 - image:
35 node: trusty-server-multi-nic
36 relationship: tosca.relationships.SupportsImage
37
38 CloudLab:
39 type: tosca.nodes.Controller
40 requirements:
41 - deployment:
42 node: MyDeployment
43 relationship: tosca.relationships.ControllerDeployment
44 properties:
45 backend_type: OpenStack
46 version: Kilo
47 auth_url: { get_script_env: [ SELF, adminrc, OS_AUTH_URL, LOCAL_FILE] }
48 admin_user: { get_script_env: [ SELF, adminrc, OS_USERNAME, LOCAL_FILE] }
49 admin_password: { get_script_env: [ SELF, adminrc, OS_PASSWORD, LOCAL_FILE] }
50 admin_tenant: { get_script_env: [ SELF, adminrc, OS_TENANT_NAME, LOCAL_FILE] }
51 rabbit_user: { get_script_env: [ SELF, controller_settings, RABBIT_USER, LOCAL_FILE] }
52 rabbit_password: { get_script_env: [ SELF, controller_settings, RABBIT_PASS, LOCAL_FILE] }
53 rabbit_host: { get_script_env: [ SELF, controller_settings, CONTROLLER_FLAT_LAN_IP, LOCAL_FILE] }
54 domain: Default
55 artifacts:
56 adminrc: /root/setup/admin-openrc.sh
57 controller_settings: /root/setup/controller_settings
58
59 mysite:
60 type: tosca.nodes.Site
61 properties:
62 no-create: True
63 no-delete: True
64 requirements:
65 - deployment:
66 node: MyDeployment
67 relationship: tosca.relationships.SiteDeployment
68 requirements:
69 - controller:
70 node: CloudLab
71 relationship: tosca.relationships.UsesController
72
73 Public shared IPv4:
74 type: tosca.nodes.NetworkTemplate
75 properties:
76 no-create: True
77 no-delete: True
78 shared_network_name: { get_artifact: [ SELF, flat_net_name, LOCAL_FILE] }
79 artifacts:
80 flat_net_name: /root/setup/flat_net_name
81
82 padmin@vicci.org:
83 type: tosca.nodes.User
84 properties:
85 no-create: True
86 no-delete: True
87 public_key: { get_artifact: [ SELF, pubkey, LOCAL_FILE ] }
88 artifacts:
89 pubkey: /root/setup/padmin_public_key