sample to create a new deployment, controller, site, slice, and compute instance
diff --git a/xos/tosca/samples/composition.yaml b/xos/tosca/samples/composition.yaml
new file mode 100644
index 0000000..7b9db03
--- /dev/null
+++ b/xos/tosca/samples/composition.yaml
@@ -0,0 +1,95 @@
+tosca_definitions_version: tosca_simple_yaml_1_0
+
+description: Two services "service_one" and "service_two" with a tenancy relationship.
+
+imports:
+ - custom_types/xos.yaml
+
+topology_template:
+ node_templates:
+ # setup the services
+
+ service_one:
+ type: tosca.nodes.Service
+ requirements:
+ - two_tenant:
+ node: service_two
+ relationship: tosca.relationships.TenantOfService
+
+ service_two:
+ type: tosca.nodes.Service
+
+ # the slices will need a site
+
+ mysite:
+ type: tosca.nodes.Site
+
+ # setup the slices
+
+ mysite_one:
+ description: Service One controller Slice
+ type: tosca.nodes.Slice
+ requirements:
+ - service:
+ node: service_one
+ relationship: tosca.relationships.MemberOfService
+ - site:
+ node: mysite
+ relationship: tosca.relationships.MemberOfSite
+
+ mysite_two:
+ description: Service Two controller Slice
+ type: tosca.nodes.Slice
+ requirements:
+ - service:
+ node: service_two
+ relationship: tosca.relationships.MemberOfService
+ - site:
+ node: mysite
+ relationship: tosca.relationships.MemberOfSite
+
+ # setup an instance in each slice
+
+ one_controller:
+ type: tosca.nodes.Compute
+ capabilities:
+ # Host container properties
+ host:
+ properties:
+ num_cpus: 1
+ disk_size: 10 GB
+ mem_size: 4 MB
+ # Guest Operating System properties
+ os:
+ properties:
+ # host Operating System image properties
+ architecture: x86_64
+ type: linux
+ distribution: rhel
+ version: 6.5
+ requirements:
+ - slice:
+ node: mysite_one
+ relationship: tosca.relationships.MemberOfSlice
+
+ two_controller:
+ type: tosca.nodes.Compute
+ capabilities:
+ # Host container properties
+ host:
+ properties:
+ num_cpus: 1
+ disk_size: 10 GB
+ mem_size: 4 MB
+ # Guest Operating System properties
+ os:
+ properties:
+ # host Operating System image properties
+ architecture: x86_64
+ type: linux
+ distribution: rhel
+ version: 6.5
+ requirements:
+ - slice:
+ node: mysite_two
+ relationship: tosca.relationships.MemberOfSlice
diff --git a/xos/tosca/samples/new_site_deploy_slice.yaml b/xos/tosca/samples/new_site_deploy_slice.yaml
new file mode 100644
index 0000000..0d2f206
--- /dev/null
+++ b/xos/tosca/samples/new_site_deploy_slice.yaml
@@ -0,0 +1,58 @@
+tosca_definitions_version: tosca_simple_yaml_1_0
+
+description: Template for deploying a single server with predefined properties.
+
+imports:
+ - custom_types/xos.yaml
+
+topology_template:
+ node_templates:
+ newdeployment:
+ type: tosca.nodes.Deployment
+
+ newcontroller:
+ type: tosca.nodes.Controller
+ requirements:
+ - deployment:
+ node: newdeployment
+ relationship: tosca.relationships.ControllerDeployment
+
+ newsite:
+ type: tosca.nodes.Site
+ requirements:
+ - deployment:
+ node: newdeployment
+ relationship: tosca.relationships.SiteDeployment
+ requirements:
+ - controller:
+ node: newcontroller
+ relationship: tosca.relationship.UsesController
+
+ newsite_tosca:
+ type: tosca.nodes.Slice
+ requirements:
+ - slice:
+ node: newsite
+ relationship: tosca.relationships.MemberOfSite
+
+ my_server:
+ type: tosca.nodes.Compute
+ capabilities:
+ # Host container properties
+ host:
+ properties:
+ num_cpus: 1
+ disk_size: 10 GB
+ mem_size: 4 MB
+ # Guest Operating System properties
+ os:
+ properties:
+ # host Operating System image properties
+ architecture: x86_64
+ type: linux
+ distribution: rhel
+ version: 6.5
+ requirements:
+ - slice:
+ node: newsite_tosca
+ relationship: tosca.relationships.MemberOfSlice
diff --git a/xos/tosca/samples/scalable_service.yaml b/xos/tosca/samples/scalable_service.yaml
new file mode 100644
index 0000000..4b2a2f6
--- /dev/null
+++ b/xos/tosca/samples/scalable_service.yaml
@@ -0,0 +1,44 @@
+tosca_definitions_version: tosca_simple_yaml_1_0
+
+description: Template for deploying a single server with predefined properties.
+
+imports:
+ - custom_types/xos.yaml
+
+topology_template:
+ node_templates:
+ mysite:
+ type: tosca.nodes.Site
+
+ mysite_tosca_scalable:
+ type: tosca.nodes.Slice
+ requirements:
+ - slice:
+ node: mysite
+ relationship: tosca.relationships.MemberOfSite
+
+ my_scalable_server:
+ type: tosca.nodes.Compute
+ capabilities:
+ # Host container properties
+ host:
+ properties:
+ num_cpus: 1
+ disk_size: 10 GB
+ mem_size: 4 MB
+ scalable:
+ min_instances: 1
+ max_instances: 25
+ default_instances: 13
+ # Guest Operating System properties
+ os:
+ properties:
+ # host Operating System image properties
+ architecture: x86_64
+ type: linux
+ distribution: rhel
+ version: 6.5
+ requirements:
+ - slice:
+ node: mysite_tosca_scalable
+ relationship: tosca.relationships.MemberOfSlice