Stone, Avi (as206k) | 879e94b | 2018-04-12 16:41:45 +0300 | [diff] [blame] | 1 | #Author: Shu Shi |
| 2 | #emaiL: shushi@research.att.com |
| 3 | |
| 4 | from toscalib.tosca_workbook import ToscaWorkBook |
| 5 | |
| 6 | workbook = ToscaWorkBook() |
| 7 | |
| 8 | workbook._import_dir('./data/tosca_model/') |
| 9 | workbook._import_dir('./data/shared_model/') |
| 10 | |
| 11 | workbook._use('foi', 'NO_PREFIX') |
| 12 | workbook._assign('policy_0', 'policy_id', 'something_filled_by_CLAMP') |
| 13 | |
| 14 | workbook._export_yaml('test_template.yaml', 'noexpand,main,rawfunc') |
| 15 | |
| 16 | workbook._add_shared_node([{'dcae.capabilities.dockerHost': 'docker_host'}, {'dcae.capabilities.composition.host': 'composition_virtual'}]) |
| 17 | |
| 18 | workbook._load_translation_db('./data/tosca_model/') |
| 19 | workbook._load_translation_db('./data/shared_model/') |
| 20 | |
| 21 | workbook._export_yaml('./data/blueprint/foi.yaml', 'cloudify,main') |
| 22 | #workbook._export_yaml('test_template2.yaml', 'noexpand,main,rawfunc') |
| 23 | |
| 24 | |