Add TOSCA files for BBSim targets in SiaB Makefile
Change-Id: I0801c3d67e2569c4bf22ef8809e2be853e985334
diff --git a/examples/bbsim-dhcp.yaml b/examples/bbsim-dhcp.yaml
new file mode 100644
index 0000000..89f14aa
--- /dev/null
+++ b/examples/bbsim-dhcp.yaml
@@ -0,0 +1,58 @@
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# Example TOSCA to configure dhcpl2relay when running BBSim standalone with SiaB
+# Load into xos-tosca with:
+# curl -H "xos-username: admin@opencord.org" -H "xos-password: letmein" -X POST --data-binary @bbsim-dhcp.yaml http://127.0.0.1:30007/run
+
+tosca_definitions_version: tosca_simple_yaml_1_0
+imports:
+ - custom_types/bngportmapping.yaml
+ - custom_types/onosapp.yaml
+ - custom_types/serviceinstanceattribute.yaml
+
+description: Create a simulated OLT Device in VOLTHA
+topology_template:
+ node_templates:
+
+ # map the BNG to a port
+ # this is not really used by BBSIM as there's no data-plane traffic,
+ # but it's required by NEM to configure the crossconnect
+ bngmapping:
+ type: tosca.nodes.BNGPortMapping
+ properties:
+ s_tag: any
+ switch_port: 1
+
+ # DHCP L2 Relay config
+ onos_app#dhcpl2relay:
+ type: tosca.nodes.ONOSApp
+ properties:
+ name: dhcpl2relay
+ must-exist: true
+
+ dhcpl2relay-config-attr:
+ type: tosca.nodes.ServiceInstanceAttribute
+ properties:
+ name: /onos/v1/network/configuration/apps/org.opencord.dhcpl2relay
+ value: >
+ {
+ "dhcpl2relay" : {
+ "useOltUplinkForServerPktInOut" : true
+ }
+ }
+ requirements:
+ - service_instance:
+ node: onos_app#dhcpl2relay
+ relationship: tosca.relationships.BelongsToOne