From c09ba66cc51c4db17503f79c05ea0b0cd0626596 Mon Sep 17 00:00:00 2001 From: zhipengh Date: Mon, 6 Mar 2017 16:16:45 +0800 Subject: Danube Release Docs Fixup patch 2 This patch provide an initial content for the docs/ release/release-notes.rst file. Further work needed. Remove policy2tosca and yang2tosca doc files in the code folder, move tosca2heat diff files to release folder. Remove all the tosca2heat original upstream rst docs due to CI failures Change-Id: I789102a7974b5ac79445f90e08e3f8252e0f4169 Signed-off-by: zhipengh --- tosca2heat/README.md | 5 - tosca2heat/diff_file_list.rst | 110 ------------------- tosca2heat/heat-translator/CONTRIBUTING.rst | 16 --- tosca2heat/heat-translator/HACKING.rst | 4 - tosca2heat/heat-translator/README.rst | 56 ---------- tosca2heat/heat-translator/doc/source/conf.py | 74 ------------- .../heat-translator/doc/source/contributing.rst | 1 - tosca2heat/heat-translator/doc/source/index.rst | 29 ----- .../heat-translator/doc/source/installation.rst | 15 --- tosca2heat/heat-translator/doc/source/usage.rst | 118 --------------------- tosca2heat/tosca-parser/CONTRIBUTING.rst | 16 --- tosca2heat/tosca-parser/HACKING.rst | 4 - tosca2heat/tosca-parser/README.rst | 54 ---------- tosca2heat/tosca-parser/doc/source/conf.py | 74 ------------- .../tosca-parser/doc/source/contributing.rst | 1 - tosca2heat/tosca-parser/doc/source/index.rst | 38 ------- .../tosca-parser/doc/source/installation.rst | 18 ---- tosca2heat/tosca-parser/doc/source/usage.rst | 16 --- 18 files changed, 649 deletions(-) delete mode 100644 tosca2heat/README.md delete mode 100644 tosca2heat/diff_file_list.rst delete mode 100644 tosca2heat/heat-translator/CONTRIBUTING.rst delete mode 100644 tosca2heat/heat-translator/HACKING.rst delete mode 100644 tosca2heat/heat-translator/README.rst delete mode 100644 tosca2heat/heat-translator/doc/source/conf.py delete mode 100644 tosca2heat/heat-translator/doc/source/contributing.rst delete mode 100644 tosca2heat/heat-translator/doc/source/index.rst delete mode 100644 tosca2heat/heat-translator/doc/source/installation.rst delete mode 100644 tosca2heat/heat-translator/doc/source/usage.rst delete mode 100644 tosca2heat/tosca-parser/CONTRIBUTING.rst delete mode 100644 tosca2heat/tosca-parser/HACKING.rst delete mode 100644 tosca2heat/tosca-parser/README.rst delete mode 100644 tosca2heat/tosca-parser/doc/source/conf.py delete mode 100644 tosca2heat/tosca-parser/doc/source/contributing.rst delete mode 100644 tosca2heat/tosca-parser/doc/source/index.rst delete mode 100644 tosca2heat/tosca-parser/doc/source/installation.rst delete mode 100644 tosca2heat/tosca-parser/doc/source/usage.rst (limited to 'tosca2heat') diff --git a/tosca2heat/README.md b/tosca2heat/README.md deleted file mode 100644 index a1f6289..0000000 --- a/tosca2heat/README.md +++ /dev/null @@ -1,5 +0,0 @@ -##TOSCA To HOT Translation## -Basic version information: -1. tosca-paser is based on the stable version of 0.7 in openstack community; -2. heat-translator is based on the stable version of 0.7 in openstack community; -3. refer to the file of diff_file_list.rst for the detail difference between parser and upstream project. diff --git a/tosca2heat/diff_file_list.rst b/tosca2heat/diff_file_list.rst deleted file mode 100644 index 79caccd..0000000 --- a/tosca2heat/diff_file_list.rst +++ /dev/null @@ -1,110 +0,0 @@ -.. This work is licensed under a Creative Commons Attribution 4.0 International License. -.. http://creativecommons.org/licenses/by/4.0 - -=================================== -1. tosca-parser difference list -=================================== - -[modified] tosca-parser/toscaparser/elements/nodetype.py -[modified] tosca-parser/toscaparser/elements/TOSCA_definition_1_0.yaml -[modified] tosca-parser/toscaparser/elements/tosca_type_validation.py -[new file] tosca-parser/toscaparser/extensions/nfv/tests/data/vRNC/Definitions/vRNC.yaml -[new file] tosca-parser/toscaparser/extensions/nfv/tests/data/vRNC/Definitions/rnc_definition.yaml -[new file] tosca-parser/toscaparser/extensions/nfv/tests/data/vRNC/TOSCA-Metadata/TOSCA.meta -[new file] tosca-parser/toscaparser/extensions/nfv/tests/data/vRNC/README.txt -[new file] tosca-parser/toscaparser/extensions/nfv/tests/test_tosca_vRNC.py -[modified] tosca-parser/toscaparser/tests/data/functions/test_get_property_with_host.yaml -[new file] tosca-parser/toscaparser/tests/data/topology_template/databasesubsystem.yaml -[modified] tosca-parser/toscaparser/tests/data/topology_template/definitions.yaml -[new file] tosca-parser/toscaparser/tests/data/topology_template/queuingsubsystem.yaml -[del file] tosca-parser/toscaparser/tests/data/topology_template/subsystem.yaml -[modified] tosca-parser/toscaparser/tests/data/topology_template/system.yaml -[new file] tosca-parser/toscaparser/tests/data/topology_template/transactionsubsystem.yaml -[modified] tosca-parser/toscaparser/tests/data/test_tosca_normative_type_by_shortname.yaml -[modified] tosca-parser/toscaparser/tests/data/tosca_single_instance_wordpress.yaml -[modified] tosca-parser/toscaparser/tests/data/tosca_single_instance_wordpress_with_local_abspath_import.yaml -[modified] tosca-parser/toscaparser/tests/data/tosca_single_instance_wordpress_with_url_import.yaml -[modified] tosca-parser/toscaparser/tests/test_functions.py -[modified] tosca-parser/toscaparser/tests/test_topology_template.py -[modified] tosca-parser/toscaparser/tests/test_toscatpl.py -[modified] tosca-parser/toscaparser/tests/test_toscatplvalidation.py -[modified] tosca-parser/toscaparser/imports.py -[modified] tosca-parser/toscaparser/nodetemplate.py -[modified] tosca-parser/toscaparser/parameters.py -[new file] tosca-parser/toscaparser/substitution_mappings.py -[modified] tosca-parser/toscaparser/topology_template.py -[modified] tosca-parser/toscaparser/tosca_template.py -[modified] tosca-parser/MANIFEST.in -[modified] tosca-parser/tox.ini - - -=================================== -2. heat-translator difference list -=================================== - -[modified] heat-translator/translator/hot/syntax/hot_resource.py -[modified] heat-translator/translator/hot/tosca/tests/test_tosca_compute.py -[modified] heat-translator/translator/hot/tosca/tests/test_tosca_policies.py -[modified] heat-translator/translator/hot/tosca/tosca_compute.py -[modified] heat-translator/translator/hot/tosca/tosca_network_network.py -[modified] heat-translator/translator/hot/tosca/tosca_policies_antilocate.py -[modified] heat-translator/translator/hot/tosca/tosca_policies_colocate.py -[modified] heat-translator/translator/hot/translate_node_templates.py -[modified] heat-translator/translator/tests/data/hot_output/network/hot_custom_network_nodes.yaml -[modified] heat-translator/translator/tests/data/hot_output/network/hot_one_server_one_network.yaml -[modified] heat-translator/translator/tests/data/hot_output/network/hot_one_server_three_networks.yaml -[modified] heat-translator/translator/tests/data/hot_output/network/hot_server_on_existing_network.yaml -[modified] heat-translator/translator/tests/data/hot_output/network/hot_two_servers_one_network.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_attachment.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_attachment_notation1_alt1.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_attachment_notation1_alt2.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_attachment_notation2_alt1.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_attachment_notation2_alt2.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_custom_relationship_type.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_blockstorage_with_relationship_template.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_multiple_blockstorage_with_attachment_alt1.yaml -[modified] heat-translator/translator/tests/data/hot_output/storage/hot_multiple_blockstorage_with_attachment_alt2.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_artifact.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_custom_type.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_custom_type_with_override.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_custom_type_with_param_override.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_elk.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_elk_from_csar.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_flavor_and_image.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_flavor_and_image_params.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_hello_world.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_hello_world_userkey.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_hello_world_userkey.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_nfv_sample.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_nodejs_mongodb_two_instances.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_policies.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_script_types.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_instance_wordpress.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_instance_wordpress_from_csar.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_server.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_server_with_defaults_with_input.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_server_with_defaults_without_input.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_single_server_without_tosca_os_version.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_software_component.yaml -[new file] heat-translator/translator/tests/data/hot_output/hot_vRNC.yaml -[modified] heat-translator/translator/tests/data/hot_output/hot_web_application.yaml -[new file] heat-translator/translator/tests/data/vRNC/Definitions/rnc_definition.yaml -[new file] heat-translator/translator/tests/data/vRNC/Definitions/vRNC.yaml -[new file] heat-translator/translator/tests/data/vRNC/Scripts/MM/mm_active_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/MM/mm_passivtiv_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/MM/mm_install.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/MM/mm_storage_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/CM/cm_active_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/CM/cm_passivtiv_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/CM/cm_install.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/DM/dm_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/DM/dm_install.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/LB/lb_configure.sh -[new file] heat-translator/translator/tests/data/vRNC/Scripts/LB/lb_install.sh -[new file] heat-translator/translator/tests/data/vRNC/TOSCA-Metadata/TOSCA.meta -[new fiel] heat-translator/translator/tests/data/vRNC/README.txt -[modified] heat-translator/translator/tests/data/test_tosca_nfv_sample.yaml -[modified] heat-translator/translator/tests/test_shell.py -[modified] heat-translator/translator/shell.py -[modified] heat-translator/MANIFEST.in -[modified] heat-translator/tox.ini diff --git a/tosca2heat/heat-translator/CONTRIBUTING.rst b/tosca2heat/heat-translator/CONTRIBUTING.rst deleted file mode 100644 index e12c422..0000000 --- a/tosca2heat/heat-translator/CONTRIBUTING.rst +++ /dev/null @@ -1,16 +0,0 @@ -If you would like to contribute to the development of OpenStack, -you must follow the steps in this page: - - http://docs.openstack.org/infra/manual/developers.html - -Once those steps have been completed, changes to OpenStack -should be submitted for review via the Gerrit tool, following -the workflow documented at: - - http://docs.openstack.org/infra/manual/developers.html#development-workflow - -Pull requests submitted through GitHub will be ignored. - -Bugs should be filed on Launchpad, not GitHub: - - https://bugs.launchpad.net/heat-translator \ No newline at end of file diff --git a/tosca2heat/heat-translator/HACKING.rst b/tosca2heat/heat-translator/HACKING.rst deleted file mode 100644 index 9c60464..0000000 --- a/tosca2heat/heat-translator/HACKING.rst +++ /dev/null @@ -1,4 +0,0 @@ -heat-translator Style Commandments -=============================================== - -Read the OpenStack Style Commandments http://docs.openstack.org/developer/hacking/ \ No newline at end of file diff --git a/tosca2heat/heat-translator/README.rst b/tosca2heat/heat-translator/README.rst deleted file mode 100644 index c8af42a..0000000 --- a/tosca2heat/heat-translator/README.rst +++ /dev/null @@ -1,56 +0,0 @@ -======================== -Team and repository tags -======================== - -.. image:: http://governance.openstack.org/badges/heat-translator.svg - :target: http://governance.openstack.org/reference/tags/index.html - -.. Change things from this point on - -=============== -Heat-Translator -=============== - -Overview --------- - -Heat-Translator is an Openstack project and licensed under Apache 2. It is a -command line tool which takes non-Heat templates as an input and produces a -Heat Orchestration Template (HOT) which can be deployed by Heat. Currently the -development and testing is done with an aim to translate OASIS Topology and -Orchestration Specification for Cloud Applications (TOSCA) templates to -HOT. However, the tool is designed to be easily extended to use with any -format other than TOSCA. - -Architecture ------------- - -Heat-Translator project takes a non-Heat template (e.g. TOSCA flat YAML -template or template embedded in TOSCA Cloud Service Archive (CSAR) format) as -an input, calls an appropriate Parser (e.g. TOSCA Parser) per the type of input -template to parse it and create an in-memory graph, maps it to Heat resources -and then produces a Heat Orchestration Template (HOT) as an output. - -How To Use ----------- -Please refer to `doc/source/usage.rst `_ - -Directory Structure -------------------- - -Three main directories related to the heat-translator are: - -1. hot: It is the generator, that has logic of converting TOSCA in memory graph to HOT YAML files. -2. common: It has all the file that can support the execution of parser and generator. -3. tests: It contains test programs and more importantly several templates which are used for testing. - -Project Info ------------- - -* License: Apache License, Version 2.0 -* Documentation: http://docs.openstack.org/developer/heat-translator/ -* Launchpad: https://launchpad.net/heat-translator -* Blueprints: https://blueprints.launchpad.net/heat-translator -* Bugs: https://bugs.launchpad.net/heat-translator -* Source: http://git.openstack.org/cgit/openstack/heat-translator/ -* IRC Channel: #openstack-heat-translator diff --git a/tosca2heat/heat-translator/doc/source/conf.py b/tosca2heat/heat-translator/doc/source/conf.py deleted file mode 100644 index e051aeb..0000000 --- a/tosca2heat/heat-translator/doc/source/conf.py +++ /dev/null @@ -1,74 +0,0 @@ -# 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. - -import os -import sys - -sys.path.insert(0, os.path.abspath('../..')) -# -- General configuration ---------------------------------------------------- - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = [ - 'sphinx.ext.autodoc', - #'sphinx.ext.intersphinx', - 'oslosphinx' -] - -# autodoc generation is a bit aggressive and a nuisance when doing heavy -# text edit cycles. -# execute "export SPHINX_DEBUG=1" in your terminal to disable - -# The suffix of source filenames. -source_suffix = '.rst' - -# The master toctree document. -master_doc = 'index' - -# General information about the project. -project = u'heat-translator' -copyright = u'2013, OpenStack Foundation' - -# If true, '()' will be appended to :func: etc. cross-reference text. -add_function_parentheses = True - -# If true, the current module name will be prepended to all description -# unit titles (such as .. function::). -add_module_names = True - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' - -# -- Options for HTML output -------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. Major themes that come with -# Sphinx are currently 'default' and 'sphinxdoc'. -# html_theme_path = ["."] -# html_theme = 'default' -# html_static_path = ['static'] - -# Output file base name for HTML help builder. -htmlhelp_basename = '%sdoc' % project - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto/manual]). -latex_documents = [ - ('index', - '%s.tex' % project, - u'%s Documentation' % project, - u'OpenStack Foundation', 'manual'), -] - -# Example configuration for intersphinx: refer to the Python standard library. -#intersphinx_mapping = {'http://docs.python.org/': None} diff --git a/tosca2heat/heat-translator/doc/source/contributing.rst b/tosca2heat/heat-translator/doc/source/contributing.rst deleted file mode 100644 index 8cb3146..0000000 --- a/tosca2heat/heat-translator/doc/source/contributing.rst +++ /dev/null @@ -1 +0,0 @@ -.. include:: ../../CONTRIBUTING.rst \ No newline at end of file diff --git a/tosca2heat/heat-translator/doc/source/index.rst b/tosca2heat/heat-translator/doc/source/index.rst deleted file mode 100644 index dd3f04f..0000000 --- a/tosca2heat/heat-translator/doc/source/index.rst +++ /dev/null @@ -1,29 +0,0 @@ -.. heat-translator documentation master file, created by - sphinx-quickstart on Tue Jul 9 22:26:36 2013. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. - -Welcome to heat-translator's documentation! -=========================================== - -The heat-translator tool is aimed to translate non-heat templates to OpenStack -Heat Orchestration Template (HOT). Initially the tool is aimed to translate -OASIS Topology and Orchestration Specification for Cloud Applications (TOSCA) -to HOT. However, the tool can be easily extended to support any non-heat -template format to produce HOT. - -Contents: - -.. toctree:: - :maxdepth: 2 - - installation - usage - contributing - -Indices and tables -================== - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/tosca2heat/heat-translator/doc/source/installation.rst b/tosca2heat/heat-translator/doc/source/installation.rst deleted file mode 100644 index 71c5237..0000000 --- a/tosca2heat/heat-translator/doc/source/installation.rst +++ /dev/null @@ -1,15 +0,0 @@ -============ -Installation -============ - -Assuming that OpenStackClient (OSC) is available in your environment, you can easily install Heat-Translator to use with OSC by following three steps:: - - git clone https://github.com/openstack/heat-translator - cd heat-translator - sudo python setup.py install - -You can also clone the project and use it without any specific OpenStack environment set up as below:: - - git clone https://github.com/openstack/heat-translator - -Heat-Translator can be installed via PyPI package as well. Refer to https://pypi.python.org/pypi/heat-translator for available packages. diff --git a/tosca2heat/heat-translator/doc/source/usage.rst b/tosca2heat/heat-translator/doc/source/usage.rst deleted file mode 100644 index 383c696..0000000 --- a/tosca2heat/heat-translator/doc/source/usage.rst +++ /dev/null @@ -1,118 +0,0 @@ -===== -Usage -===== - -Use Heat-Translator with OpenStackClient (OSC) ----------------------------------------------- -Assuming that OpenStackClient (OSC) is available in your environment, you can easily install Heat-Translator to use with OSC by following three steps:: - - git clone https://github.com/openstack/heat-translator - cd heat-translator - sudo python setup.py install - -Alternatively, you can install a particular release of Heat-Translator as available at https://pypi.python.org/pypi/heat-translator. - -Once installation is complete, Heat-Translator is ready to use. The only required argument is ``--template-file``. By default, the ``--template-type`` is set to ``tosca`` which is the -only supported template type at present. Currently you can use Heat-Translator in following three ways. - -Translate and get output on command line. For example: :: - - openstack translate template --template-file /home/openstack/heat-translator/translator/tests/data/tosca_helloworld.yaml --template-type tosca - -Translate and save output of translated file to a desired destination. For example: :: - - openstack translate template --template-file /home/openstack/heat-translator/translator/tests/data/tosca_helloworld.yaml --template-type tosca --output-file /tmp/hot_hello_world.yaml - -Do not translate but only validate template file. For example: :: - - openstack translate template --template-file /home/openstack/heat-translator/translator/tests/data/tosca_helloworld.yaml --template-type tosca --validate-only=true - -You can learn more about available options by running following help command:: - - openstack help translate template - - -Use Heat-Translator on its own ------------------------------- -Heat-Translator can be used without any specific OpenStack environment set up as below:: - - git clone https://github.com/openstack/heat-translator - python heat_translator.py --template-file== --template-type= --parameters="purpose=test" - -The heat_translator.py test program is at the root level of the project. The program has currently tested with TOSCA templates. -The only required argument is ``--template-file``. By default, the ``--template-type`` is set to ``tosca`` which is the only supported template type at present. -The value to the ``--template-file`` is a path to the file that needs to be translated. The file, flat YAML template or CSAR, can be specified as a local file in your -system or via URL. - -For example, a TOSCA hello world template can be translated by running the following command from the project location:: - - python heat_translator.py --template-file=translator/tests/data/tosca_helloworld.yaml - -This should produce a translated Heat Orchestration Template on the command line. The translated content can be saved to a desired file by setting --output-file=. -For example: :: - - python heat_translator.py --template-file=translator/tests/data/tosca_helloworld.yaml --template-type=tosca --output-file=/tmp/hot_helloworld.yaml - -An optional argument can be provided to handle user inputs parameters. Also, a template file can only be validated instead of translation by using --validate-only=true -optional argument. The command below shows an example usage:: - - python heat_translator.py --template-file= --template-type= --validate-only=true - -Alternatively, you can install a particular release of Heat-Translator as available at https://pypi.python.org/pypi/heat-translator. -In this case, you can simply run translation via CLI entry point:: - heat-translator --template-file=translator/tests/data/tosca_helloworld.yaml --template-type=tosca - -Things To Consider ------------------- -* When use Heat-Translator in an OpenStack environment, please ensure that you have one or more preferred flavors and images available in your OpenStack - environment. To find an appropriate flavor and image, that meets constraints defined in the TOSCA template for the HOST and OS capabilities of TOSCA Compute node, - the Heat-Translator project first runs a query against Nova flavors and Glance images. During the query call, it uses the metadata of flavors and images. - If call to Nova or Glance can not be made or no flavor or image is found, the Heat-Translator project will set flavor and image from a pre-defined set of values (as listed in /home/openstack/heat-translator/translator/hot/tosca/tosca_compute.py) - with the best possible match to the constraints defined in the TOSCA template. -* The ``key_name`` property of Nova server is irrelevant to the TOSCA specification and can not be used in TOSCA template. In order to use it in - the translated templates, the user must provide it via parameters, and the heat-translator will set it to all resources of ``OS::Nova::Server`` type. -* Since properties of TOSCA Compute OS and HOST capabilities are optional, the user should make sure that either they set these properties correctly - in the TOSCA template or provide them via CLI parameters in order to find best match of flavor and image. -* The ``flavor`` and ``image`` properties of ``OS::Nova::Server`` resource is irrelevant to the TOSCA specification and can not be used in the TOSCA - template as such. Heat-Translator sets these properties in the translated template based on constraints defined per TOSCA Compute OS and HOST - capabilities. However, user may required to use these properties in template in certain circumstances, so in that case, TOSCA Compute can be extended - with these properties and later used in the node template. For a good example, refer to the ``translator/tests/data/test_tosca_flavor_and_image.yaml`` test - template. -* The Heat-Translator can be used to automatically deploy translated TOSCA template given that your environment has python-heatclient and python-keystoneclient. - This can be achieved by providing ``--deploy`` argument to the Heat-Translator. You can provide desired stack name by providing it as ``--stack-name `` - argument. If you do not provide ``--stack-name``, an unique name will be created and used. - Below is an example command to deploy translated template with a desired stack name:: - heat-translator --template-file translator/tests/data/tosca_helloworld.yaml --stack-name mystack --deploy -* The Heat-Translator supports translation of TOSCA templates to Heat Senlin - resources (e.g. ``OS::Senlin::Cluster``) but that requires to use a specific - TOSCA node type called ``tosca.policies.Scaling.Cluster``. - The ``tosca.policies.Scaling.Cluster`` is a custom type that derives from - ``tosca.policies.Scaling``. For example usage, refer to the - ``tosca_cluster_autoscaling.yaml`` and ``hot_cluster_autoscaling.yaml`` - provided under the ``translator/tests/data/autoscaling`` and - ``translator/tests/data/hot_output/autoscaling`` directories respectively in - the heat-translator project (``https://github.com/openstack/heat-translator``). - When you use ``tosca.policies.Scaling`` normative node type, the - Heat-Translator will translate it to ``OS::Heat::AutoScalingGroup`` Heat - resource. Related example templates, ``tosca_autoscaling.yaml`` and - ``hot_autoscaling.yaml`` can be found for reference purposes under the same - directory structure mentioned above. -* With the version 0.7.0 of Heat-Translator, output of multiple template files - (for example, nested templates in autoscaling) can be accessed via newly - introduced API called ``translate_to_yaml_files_dict()`` - where ```` is the name of file where you want to store parent - HOT template. The return value of this API call will be a dictionary in HOT - YAML with one or multiple file names as keys and translated content as values. - In order to use this on the command line, simply invoke Heat-Translator with - ``--output-file`` argument. Here, the parent template will be stored in the - value specified to the ``--output-file``. Whereas, child templates, if any, - will be saved at the same location of the parent template. - - Below is an example of how to call the API in your code, where - ``translator`` is an instance of Heat-Translator:: - - yaml_files = translator.translate_to_yaml_files_dict(filename) - - Below is an example of how to use this on the command line:: - - heat-translator --template-file translator/tests/data/autoscaling/tosca_autoscaling.yaml --output-file /tmp/hot.yaml \ No newline at end of file diff --git a/tosca2heat/tosca-parser/CONTRIBUTING.rst b/tosca2heat/tosca-parser/CONTRIBUTING.rst deleted file mode 100644 index 7366825..0000000 --- a/tosca2heat/tosca-parser/CONTRIBUTING.rst +++ /dev/null @@ -1,16 +0,0 @@ -If you would like to contribute to the development of OpenStack, -you must follow the steps in this page: - - http://docs.openstack.org/infra/manual/developers.html - -Once those steps have been completed, changes to OpenStack -should be submitted for review via the Gerrit tool, following -the workflow documented at: - - http://docs.openstack.org/infra/manual/developers.html#development-workflow - -Pull requests submitted through GitHub will be ignored. - -Bugs should be filed on Launchpad, not GitHub: - - https://bugs.launchpad.net/tosca-parser \ No newline at end of file diff --git a/tosca2heat/tosca-parser/HACKING.rst b/tosca2heat/tosca-parser/HACKING.rst deleted file mode 100644 index 60505f1..0000000 --- a/tosca2heat/tosca-parser/HACKING.rst +++ /dev/null @@ -1,4 +0,0 @@ -tosca-parser Style Commandments -=============================================== - -Read the OpenStack Style Commandments http://docs.openstack.org/developer/hacking/ \ No newline at end of file diff --git a/tosca2heat/tosca-parser/README.rst b/tosca2heat/tosca-parser/README.rst deleted file mode 100644 index 0f94072..0000000 --- a/tosca2heat/tosca-parser/README.rst +++ /dev/null @@ -1,54 +0,0 @@ -======================== -Team and repository tags -======================== - -.. image:: http://governance.openstack.org/badges/tosca-parser.svg - :target: http://governance.openstack.org/reference/tags/index.html - -.. Change things from this point on - -=============== -TOSCA Parser -=============== - -Overview --------- - -The TOSCA Parser is an OpenStack project and licensed under Apache 2. It is -developed to parse TOSCA Simple Profile in YAML. It reads the TOSCA templates -and creates an in-memory graph of TOSCA nodes and their relationship. - -Architecture ------------- - -The TOSCA Parser takes TOSCA YAML template or TOSCA Cloud Service Archive (CSAR) -file as an input, with optional input of dictionary of needed parameters with their -values, and produces in-memory objects of different TOSCA elements with their -relationship to each other. It also creates a graph of TOSCA node templates and their -relationship. - -The ToscaTemplate class located in the toscaparser/tosca_template.py is an entry -class of the parser and various functionality of parser can be used by initiating -this class. In order to see an example usage of TOSCA Parser from a separate tool, -refer to the OpenStack heat-translator class TranslateTemplate located in the -translator/osc/v1/translate.py module. The toscaparser/shell.py module of tosca-parser -also provides a good reference on how to invoke TOSCA Parser from Command Line Interface. - -The toscaparser/elements sub-directory contains various modules to handle -various TOSCA type elements like node type, relationship type etc. The -entity_type.py module is a parent of all type elements. The toscaparser -directory contains various python module to handle service template including -topology template, node templates, relationship templates etc. The -entity_template.py is a parent of all template elements. - - -How To Use ----------- -Please refer to `doc/source/usage.rst `_ - -Project Info ------------- - -* License: Apache License, Version 2.0 -* Source: http://git.openstack.org/cgit/openstack/tosca-parser/ - diff --git a/tosca2heat/tosca-parser/doc/source/conf.py b/tosca2heat/tosca-parser/doc/source/conf.py deleted file mode 100644 index d5d9189..0000000 --- a/tosca2heat/tosca-parser/doc/source/conf.py +++ /dev/null @@ -1,74 +0,0 @@ -# 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. - -import os -import sys - -sys.path.insert(0, os.path.abspath('../..')) -# -- General configuration ---------------------------------------------------- - -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = [ - 'sphinx.ext.autodoc', - #'sphinx.ext.intersphinx', - 'oslosphinx' -] - -# autodoc generation is a bit aggressive and a nuisance when doing heavy -# text edit cycles. -# execute "export SPHINX_DEBUG=1" in your terminal to disable - -# The suffix of source filenames. -source_suffix = '.rst' - -# The master toctree document. -master_doc = 'index' - -# General information about the project. -project = u'tosca-parser' -copyright = u'2013, OpenStack Foundation' - -# If true, '()' will be appended to :func: etc. cross-reference text. -add_function_parentheses = True - -# If true, the current module name will be prepended to all description -# unit titles (such as .. function::). -add_module_names = True - -# The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' - -# -- Options for HTML output -------------------------------------------------- - -# The theme to use for HTML and HTML Help pages. Major themes that come with -# Sphinx are currently 'default' and 'sphinxdoc'. -# html_theme_path = ["."] -# html_theme = 'default' -# html_static_path = ['static'] - -# Output file base name for HTML help builder. -htmlhelp_basename = '%sdoc' % project - -# Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, author, documentclass -# [howto/manual]). -latex_documents = [ - ('index', - '%s.tex' % project, - u'%s Documentation' % project, - u'OpenStack Foundation', 'manual'), -] - -# Example configuration for intersphinx: refer to the Python standard library. -#intersphinx_mapping = {'http://docs.python.org/': None} diff --git a/tosca2heat/tosca-parser/doc/source/contributing.rst b/tosca2heat/tosca-parser/doc/source/contributing.rst deleted file mode 100644 index 8cb3146..0000000 --- a/tosca2heat/tosca-parser/doc/source/contributing.rst +++ /dev/null @@ -1 +0,0 @@ -.. include:: ../../CONTRIBUTING.rst \ No newline at end of file diff --git a/tosca2heat/tosca-parser/doc/source/index.rst b/tosca2heat/tosca-parser/doc/source/index.rst deleted file mode 100644 index c3894f4..0000000 --- a/tosca2heat/tosca-parser/doc/source/index.rst +++ /dev/null @@ -1,38 +0,0 @@ -.. tosca-parser documentation master file, created by - sphinx-quickstart on Tue Jul 9 22:26:36 2013. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. - -Welcome to tosca-parser's documentation! -=========================================== - -The TOSCA Parser is developed to parse TOSCA Simple Profile in YAML. It reads -the TOSCA templates and creates an in-memory graph of TOSCA nodes and their -relationship. - -The TOSCA Parser can also be used for parsing TOSCA Simple Profile for Network -Functions Virtualization (NFV). The work to provide such a support was started -with the release of TOSCA Parser 0.4.0 PyPI release and it is ongoing. -The TOSCA Simple Profile for NFV can be accessed by using TOSCA version -"tosca_simple_profile_for_nfv_1_0_0" in the template. - -The TOSCA Parser now supports profile definition extensions that can be -accessed via a custom tosca_definitions_version. Extensions can be added by -creating a module in the "toscaparser/extensions" directory. See the "nfv" -module for an example. - -Contents: - -.. toctree:: - :maxdepth: 2 - - installation - usage - contributing - -Indices and tables -================== - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/tosca2heat/tosca-parser/doc/source/installation.rst b/tosca2heat/tosca-parser/doc/source/installation.rst deleted file mode 100644 index 5476d41..0000000 --- a/tosca2heat/tosca-parser/doc/source/installation.rst +++ /dev/null @@ -1,18 +0,0 @@ -============ -Installation -============ - -PyPI Installation ------------------ -Tosca-Parser can be installed via a PyPI package. Refer to https://pypi.python.org/pypi/tosca-parser for available packages. -The latest release can be simply installed by running the following command:: - - sudo pip install tosca-parser - -Manual Installation -------------------- -You can manually install the latest code available at the TOSCA-Parser github repository by following these steps:: - - git clone https://github.com/openstack/tosca-parser - cd tosca-parser - sudo python setup.py install diff --git a/tosca2heat/tosca-parser/doc/source/usage.rst b/tosca2heat/tosca-parser/doc/source/usage.rst deleted file mode 100644 index 2b822a8..0000000 --- a/tosca2heat/tosca-parser/doc/source/usage.rst +++ /dev/null @@ -1,16 +0,0 @@ -===== -Usage -===== - -The TOSCA Parser can be used as a library by any client program, for example, -OpenStack heat-translator uses it to translate TOSCA to Heat Orchestration -Template (HOT). - -For an easy reference on how TOSCA Parser can be used programmatically or to -test that the a TOSCA template passes validation, refer to the tosca_parser.py -test program which is located at the root level of the project. Alternatively, -you can install 0.3.0 or higher PyPI release of TOSCA-Parser as available at the -https://pypi.python.org/pypi/tosca-parser and test use the parser via CLI -entry point as:: - tosca-parser --template-file=toscaparser/tests/data/tosca_helloworld.yaml -The value to the --template-file is required to be a relative or an absolute path. -- cgit 1.2.3-korg