1 ========================
3 ========================
6 ===========================
8 Parser is an open source project and licensed under Apache 2. Parser will help
9 to provide a tooling mechanism, by parsing Telecom operators’ VNF descriptors
10 (YANG templates) into TOSCA templates and then further translate TOSCA
11 templates into certain common templates, which could be used in IaaS orchestration
12 projects like OpenStack Heat.
15 ==========================
17 Parser requires the following to be installed.
22 Please follow the below installation steps.
24 Step 1: Clone pyang tool or download the zip file from the following link.
25 git clone https://github.com/mbj4668/pyang.git
27 wget https://github.com/mbj4668/pyang/archive/master.zip
29 Step 2: Change directory to the downloaded directory and run the setup file.
36 Please follow the below installation link.
37 http://lxml.de/installation.html
41 ============================
43 Please follow the below installation steps to install parser.
45 Step 1: Clone the parser project.
46 git clone https://gerrit.opnfv.org/gerrit/parser
49 ===========================
51 Step 1: Change directory to where the scripts are present.
54 Step 2: Copy the YANG file which needs to be converted into TOSCA to
55 current (parser/yang2tosca) folder.
57 Step 3: Run the python script "parser.py" with the YANG file as an input option.
58 python parser.py -n "YANG filename"
60 python parser.py -n example.yaml
62 Step 4: Verify the TOSCA YAMl which file has been created with the same name
63 as the YANG file with a “_tosca” suffix.
64 cat "YANG filename_tosca.yaml"
66 cat example_tosca.yaml