blob: 1263bd3d2884228ad4c4b342ff3d4cebc5b3ca26 [file] [log] [blame]
Andy Bavier7a080492018-08-30 14:26:09 -07001---
2# Copyright 2018-present Open Networking Foundation
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
16tosca_definitions_version: tosca_simple_yaml_1_0
17imports:
18 - custom_types/rcordsubscriber.yaml
Andy Bavieraf38f0d2019-04-19 16:03:34 -070019{{- if .Values.bandwidthProfiles }}
20 - custom_types/bandwidthprofile.yaml
21{{- end }}
Andy Bavier7a080492018-08-30 14:26:09 -070022
23description: Pre-provsion a subscriber
24
25topology_template:
26 node_templates:
27
Andy Bavieraf38f0d2019-04-19 16:03:34 -070028{{- if .Values.bandwidthProfiles }}
29 # Bronze bandwidthprofile for subscriber
30 bronze_bp:
31 type: tosca.nodes.BandwidthProfile
32 properties:
33 air: 99999
34 cbs: 99999
35 cir: 99999
36 ebs: 99999
37 eir: 99999
38 name: Bronze
39{{- end }}
40
Andy Baviere21a5f52019-05-28 15:39:52 -070041 # Pre-provision the subscribers
42{{- range $i, $junk := until (.Values.numOlts|int) }}
43
44 house_{{ $i }}:
Andy Bavier7a080492018-08-30 14:26:09 -070045 type: tosca.nodes.RCORDSubscriber
46 properties:
Andy Baviere21a5f52019-05-28 15:39:52 -070047 name: QQClient{{ $i }}
Andy Bavier7a080492018-08-30 14:26:09 -070048 status: pre-provisioned
49 c_tag: 111
Andy Baviere21a5f52019-05-28 15:39:52 -070050 s_tag: {{ add 222 $i }}
51 {{- if $.Values.legacyPonsim }}
Andy Bavieraf38f0d2019-04-19 16:03:34 -070052 onu_device: PSMO12345678
Andy Baviere21a5f52019-05-28 15:39:52 -070053 {{- else }}
54 onu_device: PSMO{{ printf "%04d" $i }}0000
55 {{- end }}
56 {{- if $.Values.bandwidthProfiles }}
Andy Bavieraf38f0d2019-04-19 16:03:34 -070057 requirements:
58 - upstream_bps:
59 node: bronze_bp
60 relationship: tosca.relationships.BelongsToOne
61 - downstream_bps:
62 node: bronze_bp
63 relationship: tosca.relationships.BelongsToOne
Andy Baviere21a5f52019-05-28 15:39:52 -070064 {{- end }}
Andy Bavieraf38f0d2019-04-19 16:03:34 -070065{{- end }}