summaryrefslogtreecommitdiffstats
path: root/docs/refspec/open-o/vnf-package/NS&VNF Package Specification-v0.4.rst
blob: 542475bf7b659de5971372ba422b0409761cb60e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
.. Copyright 2017 (HUAWEI)
.. This file is licensed under the CREATIVE COMMONS ATTRIBUTION 4.0 INTERNATIONAL LICENSE
.. Full license text at https://creativecommons.org/licenses/by/4.0/legalcode

.. contents::
   :depth: 3
..

NS&VNF Package Specification V0.4
=======================================

Scope
-------------

The scope of the present document is to describe the NS&VNF CSAR model
specification for OPENO.

Terms, Definitions and Abbreviations
----------------------------------------------

For the purposes of the present document, the following abbreviations
apply:

+-----------------------------------+-----------------------------------+
| Abbreviation                      | Definition                        |
+===================================+===================================+
| CSAR                              | TOSCA Cloud Service Archive       |
+-----------------------------------+-----------------------------------+
| CSAR Model                        | ……                                |
+-----------------------------------+-----------------------------------+
| NS                                | Network Service                   |
+-----------------------------------+-----------------------------------+
| NSD                               | Network Service Descriptor        |
+-----------------------------------+-----------------------------------+
| TOSCA                             | Topology and Orchestration        |
|                                   | Specification for Cloud           |
|                                   | Applications                      |
+-----------------------------------+-----------------------------------+
| VNF                               | Virtual Network Function          |
+-----------------------------------+-----------------------------------+
| VNFD                              | Virtual Network Function          |
|                                   | Descriptor                        |
+-----------------------------------+-----------------------------------+

NS&VNF CSAR Model Definitio
----------------------------------------

In OPENO, TOSCA language is adopted to describe the NS/VNF Package. This
document refers to “TOSCA Simple Profile YAML v1.0” and
“tosca-nfv-profile-wd04-Rev06” specification. Base on those
specifications, these clauses below focus on extension and satisfy the
open NS/VNF package requirements.

CSAR Introduction
~~~~~~~~~~~~~~~~~~~~~~~~

A CSAR is a zip file containing at least two directories, the
TOSCA-Metadata directory and the Definitions directory. Beyond that,
other directories MAY be contained in a CSAR, i.e. the creator of a CSAR
has all freedom to define the content of a CSAR and the structuring of
this content as appropriate for the cloud application.

The TOSCA-Metadata directory contains metadata describing the other
content of the CSAR. This metadata is referred to as TOSCA meta file.
This file is named TOSCA and has the file extension .meta.

The Definitions directory contains one or more TOSCA Definitions
documents (file extension .tosca). These Definitions files typically
contain definitions related to the cloud application of the CSAR. In
addition, CSARs can contain just the definition of elements for re-use
in other contexts. For example, a CSAR might be used to package a set of
Node Types and Relationship Types with their respective implementations
that can then be used by Service Templates provided in other CSARs. In
cases where a complete cloud application is packaged in a CSAR, one of
the Definitions documents in the Definitions directory MUST contain a
Service Template definition that defines the structure and behavior of
the cloud application.

NS CSAR Model Structure
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+----------------------+----------------------+----------------------+
| Dirctory/Files       | Qualifier            | Description          |
+======================+======================+======================+
| /TOSCA-Metadata/TOSC | M                    | Describing the other |
| A.meta               |                      | content of the CSAR. |
|                      |                      |                      |
|                      |                      | The detail of        |
|                      |                      | “TOSCA.meta” format  |
|                      |                      | refers to clause     |
|                      |                      | 3.4.                 |
+----------------------+----------------------+----------------------+
| /Definitions         | M                    | Including simple     |
|                      |                      | TOSCA Type           |
|                      |                      | Definition and       |
|                      |                      | NSD/VNFD definition  |
|                      |                      | files                |
|                      |                      |                      |
|                      |                      | The detail of NSD    |
|                      |                      | format refers to <   |
|                      |                      | NSD Specification>.  |
+----------------------+----------------------+----------------------+
| /checksum.lst        | O                    | It is a txt file for |
|                      |                      | record the important |
|                      |                      | file checksum.       |
|                      |                      |                      |
|                      |                      | Such as              |
|                      |                      | SoftwareImages files |
|                      |                      | or AppSoftware       |
|                      |                      | files.               |
|                      |                      |                      |
|                      |                      | The detail of        |
|                      |                      | “checksum.lst”       |
|                      |                      | format refers to     |
|                      |                      | clause 3.6.          |
+----------------------+----------------------+----------------------+
| /Policies            | O                    | Policies Definition  |
|                      |                      | files.               |
+----------------------+----------------------+----------------------+
| /Plans               | O                    | LCM Workflow Plans   |
|                      |                      |                      |
|                      |                      | Deploy, Termination, |
|                      |                      | etc.                 |
+----------------------+----------------------+----------------------+

VNF CSAR Model Structure
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+----------------------+----------------------+----------------------+
| Dirctory/Files       | Qualifier            | Description          |
+======================+======================+======================+
| /TOSCA-Metadata/TOSC | M                    | Describing the other |
| A.meta               |                      | content of the CSAR. |
|                      |                      |                      |
|                      |                      | The detail of        |
|                      |                      | “TOSCA.meta” format  |
|                      |                      | refers to clause     |
|                      |                      | 3.3.                 |
+----------------------+----------------------+----------------------+
| /Definitions         | M                    | Including simple     |
|                      |                      | TOSCA Type           |
|                      |                      | Definition and       |
|                      |                      | NSD/VNFD definition  |
|                      |                      | files                |
|                      |                      |                      |
|                      |                      | The detail of VNFD   |
|                      |                      | format refers to <   |
|                      |                      | VNFD pecification>.  |
+----------------------+----------------------+----------------------+
| /checksum.lst        | O                    | It is a txt file for |
|                      |                      | record the important |
|                      |                      | file checksum.       |
|                      |                      |                      |
|                      |                      | Such as              |
|                      |                      | SoftwareImages files |
|                      |                      | or AppSoftware       |
|                      |                      | files.               |
|                      |                      |                      |
|                      |                      | The detail of        |
|                      |                      | “checksum.lst”       |
|                      |                      | format refers to     |
|                      |                      | clause 3.4.          |
+----------------------+----------------------+----------------------+
| /SoftwareImages      | O                    | VNF Image directory. |
|                      |                      |                      |
|                      |                      | The Images can be in |
|                      |                      | a fixed URL, such as |
|                      |                      | in the catalog       |
|                      |                      | public directory on  |
|                      |                      | order to be imported |
|                      |                      | by VNFD file.        |
+----------------------+----------------------+----------------------+
| /AppSoftwares        | O                    | VNF Software         |
|                      |                      | directory            |
|                      |                      |                      |
|                      |                      | The VNF Software can |
|                      |                      | be in a fixed URL,   |
|                      |                      | such as in the       |
|                      |                      | catalog public       |
|                      |                      | directory on order   |
|                      |                      | to be imported by    |
|                      |                      | VNFD file.           |
+----------------------+----------------------+----------------------+
| /Policies            | O                    | Policies Definition  |
|                      |                      | files.               |
+----------------------+----------------------+----------------------+
| /Scripts             | O                    | LCM Scripts          |
|                      |                      |                      |
|                      |                      | Deploy, Termination, |
|                      |                      | Test, etc.           |
+----------------------+----------------------+----------------------+

TOSCA Meta File Definition
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The TOSCA meta file includes metadata that allows interpreting the
various artifacts within the CSAR properly. The TOSCA.meta file is
contained in the TOSCA-Metadata directory of the CSAR.

A TOSCA meta file consists of name/value pairs. The name-part of a
name/value pair is followed by a colon, followed by a blank, followed by
the value-part of the name/value pair. The name MUST NOT contain a
colon. Values that represent binary data MUST be base64 encoded. Values
that extend beyond one line can be spread over multiple lines if each
subsequent line starts with at least one space. Such spaces are then
collapsed when the value string is read.

+-----------------+
| <name>: <value> |
+-----------------+

Each name/value pair is in a separate line. A list of related name/value
pairs, i.e. a list of consecutive name/value pairs describing a
particular file in a CSAR, is called a block. Blocks are separated by an
empty line. The first block, called block_0, is metadata about the CSAR
itself. All other blocks represent metadata of files in the CSAR.

The structure of block_0 in the TOSCA meta file is as follows:

+--------------------------------------+
| TOSCA-Meta-File-Version: digit.digit |
|                                      |
| CSAR-Version: digit.digit            |
|                                      |
| Created-By: string                   |
|                                      |
| Entry-Definitions: string ?          |
+--------------------------------------+

The name/value pairs are as follows:

-  TOSCA-Meta-File-Version: This is the version number of the TOSCA meta
   file format. The value MUST be “1.0” in the current version of the
   TOSCA specification.

-  CSAR-Version: This is the version number of the CSAR specification.
   The value MUST be “1.0” in the current version of the TOSCA
   specification.

-  Created-By: The person or vendor, respectively, who created the CSAR.

-  Entry-Definitions: This OPTIONAL name/value pair references a TOSCA
   Definitions file from the Definitions directory of the CSAR that
   SHOULD be used as entry point for processing the contents of the
   CSAR.

    Note, that a CSAR may contain multiple Definitions files. One reason
    for this is completeness, e.g. a Service Template defined in one of
    the Definitions files could refer to Node Types defined in another
    Definitions file that might be included in the Definitions directory
    to avoid importing it from external locations. The Entry-Definitions
    name/value pair is a hint to allow optimized processing of the set
    of files in the Definitions directory.

For an example:

csar_vfw.zip

+-----------------------------------------------+
| TOSCA-Meta-File-Version: 1.0                  |
|                                               |
| CSAR-Version: 1.0                             |
|                                               |
| Created-By: zte                               |
|                                               |
| Entry-Definitions: Definitions/tosca_vfw.yaml |
+-----------------------------------------------+

CSAR Meta File Definition
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Describing the content of the CSAR, including type(GSAR/SSAR/NSAR/NFAR),
provider, version.

+----------------+-----------+---------------------+
| Dirctory/Files | Qualifier | Description         |
+================+===========+=====================+
| type           | M         | GSAR/SSAR/NSAR/NFAR |
+----------------+-----------+---------------------+
| provider       | M         |                     |
+----------------+-----------+---------------------+
| version        | M         |                     |
+----------------+-----------+---------------------+

For an example:

+---------------+
| Type: NSAR    |
|               |
| Provider: ZTE |
|               |
| Version: v1.0 |
+---------------+

Checksum File Definition
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

File Name: checksum.lst

Content:

[File related file path]:[checksum(MD5)]

For an example:

/SoftwareImages/zte_vmb_qcow2.img:8a683566bcc7801226b3d8b0cf35fd97

/AppSoftwares/zte_nf_version.zip:7b8955fbb77654635b5c8a9be3aa854