Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 1 | tosca_definitions_version: tosca_simple_yaml_1_0 |
| 2 | |
| 3 | imports: |
| 4 | - custom_types/xos.yaml |
| 5 | |
| 6 | description: deployment config, generated by platform-install |
| 7 | |
| 8 | topology_template: |
| 9 | node_templates: |
| 10 | |
| 11 | # Flavors |
| 12 | |
| 13 | {% for flavor in deployment_flavors %} |
| 14 | {{ flavor }}: |
| 15 | type: tosca.nodes.Flavor |
| 16 | |
| 17 | {% endfor %} |
| 18 | |
| 19 | # Deployment |
| 20 | {{ deployment_type }}: |
| 21 | type: tosca.nodes.Deployment |
| 22 | requirements: |
| 23 | {% for flavor in deployment_flavors %} |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 24 | - {{ flavor }}: |
| 25 | node: {{ flavor }} |
| 26 | relationship: tosca.relationships.SupportsFlavor |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 27 | |
| 28 | {% endfor %} |
| 29 | |
| 30 | # Site |
| 31 | {{ site_name }}: |
| 32 | type: tosca.nodes.Site |
| 33 | properties: |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 34 | display_name: {{ site_humanname }} |
| 35 | site_url: http://{{ site_name }}.opencloud.us/ |
| 36 | hosts_nodes: true |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 37 | requirements: |
| 38 | - deployment: |
| 39 | node: {{ deployment_type }} |
| 40 | relationship: tosca.relationships.MemberOfDeployment |
| 41 | |
| 42 | # Attach the Tenant view to the deployment |
| 43 | Tenant: |
| 44 | type: tosca.nodes.DashboardView |
| 45 | properties: |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 46 | no-create: true |
| 47 | no-delete: true |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 48 | requirements: |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 49 | - deployment: |
| 50 | node: {{ deployment_type }} |
| 51 | relationship: tosca.relationships.SupportsDeployment |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 52 | |
| 53 | # XOS Users |
Zack Williams | a276311 | 2017-01-03 11:38:38 -0700 | [diff] [blame] | 54 | # Default admin user account |
| 55 | {{ xos_admin_user }}: |
| 56 | type: tosca.nodes.User |
| 57 | properties: |
| 58 | password: {{ xos_admin_pass }} |
| 59 | firstname: {{ xos_admin_first }} |
| 60 | lastname: {{ xos_admin_last }} |
| 61 | is_admin: True |
| 62 | requirements: |
| 63 | - site: |
| 64 | node: {{ site_name }} |
| 65 | relationship: tosca.relationships.MemberOfSite |
| 66 | - tenant_dashboard: |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 67 | node: Tenant |
| 68 | relationship: tosca.relationships.UsesDashboard |
Zack Williams | a276311 | 2017-01-03 11:38:38 -0700 | [diff] [blame] | 69 | |
| 70 | # All other users |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 71 | {% for user in xos_users %} |
| 72 | {{ user.email }}: |
| 73 | type: tosca.nodes.User |
| 74 | properties: |
| 75 | password: {{ user.password }} |
| 76 | firstname: {{ user.first | default(user.email) }} |
| 77 | lastname: {{ user.last | default("unknown") }} |
| 78 | is_admin: {{ user.admin | default("false") }} |
| 79 | requirements: |
| 80 | - site: |
| 81 | node: {{ site_name }} |
| 82 | relationship: tosca.relationships.MemberOfSite |
| 83 | - tenant_dashboard: |
Zack Williams | 1396aa3 | 2017-06-06 10:28:29 -0700 | [diff] [blame] | 84 | node: Tenant |
| 85 | relationship: tosca.relationships.UsesDashboard |
Zack Williams | 682450e | 2016-11-19 09:04:41 -0700 | [diff] [blame] | 86 | |
| 87 | {% endfor %} |
| 88 | |