You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
-Welcome to snf-occi's documentation!
+snf-occi's documentation!
====================================
-snf-occi implements OCCI specifications to synnefo's API in order to achieve greater interoperability in common tasks refering cyclades management.
+**snf-occi** snf-occi implements the OCCI specification on top of synnefo’s API in order to achieve greater interoperability in common tasks referring cyclades management. This module is a translation bridge between OCCI and the Openstack API and is designed to be as independent as possible from the rest IaaS, providing an OCCI compatibility layer to other services using Openstack API.
+
+**snf-occi** is based in modules provided by kamaki cli-tool when dealing with REST API calls to Openstack.
.. toctree::
:maxdepth: 2
About OCCI
----------
-Current OCCI specification consists of the following three documents:
+The current OCCI specification consists of the following three documents:
* `OCCI Core <http://ogf.org/documents/GFD.183.pdf>`_
* `OCCI Infrastructure <http://ogf.org/documents/GFD.184.pdf>`_
OCCI and Cyclades
-----------------
-OCCI implementation in Cyclades is going to be based in the **OCCI Infrastructure** specifications, in which common Cloud IaaS components are described. Below you can see the matching components between OCCI and Cyclades:
-
-+----------------+------------------+
-|OCCI |Cyclades |
-+================+==================+
-|Compute linked |Synnefo servers |
-|to Storage | |
-+----------------+------------------+
-|Mixin |Synnefo images |
-| | |
-+----------------+------------------+
-|Mixin |Synnefo flavors |
-+----------------+------------------+
-|Network |Network and |
-| |NetworkInterfaces |
-| |from |
-| |synnefo.db.models |
-+----------------+------------------+
-|NetworkInterface|NetworkLink in |
-| |synnefo.db.models |
-+----------------+------------------+
+The OCCI implementation in Cyclades is going to be based in the OCCI Infrastructure specification, in which common Cloud IaaS components are described. The correspondence between OCCI and Cyclades is as follows:
+
++-------------------------+-------------------------+
+|OCCI |Cyclades |
++=========================+=========================+
+|Compute |Synnefo servers |
++-------------------------+-------------------------+
+|OS Template |Synnefo images |
++-------------------------+-------------------------+
+|Resource Template |Synnefo flavors |
++-------------------------+-------------------------+
+|Networking |NA |
++-------------------------+-------------------------+
+|Storage |NA |
++-------------------------+-------------------------+
+
+
**Note:** Metadata info in synnefo's servers cannot be represented (clearly) using OCCI's components.
-Call mapping from OCCI to Cyclades API
----------------------------------------
-Due to OCCI's structure there cannot be straightforward mapping to Cyclades/OpenStack API. The missing elements are:
+OCCI requirements
+------------------
+Due to OCCI's structure there cannot be straightforward mapping to Cyclades/OpenStack API. The missing elements are networking and storage capabilities using current Cyclades API.
-* Networking capabilities using current Cyclades API (networking is supported, but not in OCCI's format)
-* OCCI seperates the compute resource from the storage or image/flavor. As a result synnefo's servers cannot be represented only with OCCI's Compute.
+OCCI operations
+****************
-OCCI operations-Mapping
-***********************
-
-Below you can see the required procedures/operations for OCCI compatibility, and their mappings to Cyclades API (if possible).
+Below you can see the required procedures/operations for OCCI compatibility.
* Handling the query interface
* Query interface must be found under path /-/
* Operations on Resource instances
* Creating a resource instance
- * Compute: api.server.create_server()
- * Network: -
- * Storage: -
* Retrieving a resource instance
- * Compute: api.server.get_server_details()
- * Network: -
- * Storage: -
* Partial update of a resource instance
- * Compute: api.actions.resize()
- * Network: -
- * Storage: -
* Full update of a resource instance
- * Compute: -
- * Network: -
- * Storage: -
* Delete a resource instance
- * Compute: api.server.delete_server()
- * Network: -
- * Storage: -
* Triggering an action on a resource instance
- * Compute: api.actions.start(), api.actions.shutdown(), api.actions.reboot()
- * Network: -
- * Storage: -
-* Handling Link instances **(not well-defined in Cyclades API)**
- * Inline creation of a Link instance
- * Retrieving Resource instances with defined Links
- * Creating of Link Resource instance
+* Handling Link instances
+ * Inline creation of a Link instance
+ * Retrieving Resource instances with defined Links
+ * Creating of Link Resource instance
OCCI client/server library
==========================
-occi-py is a generic library implementation of the Open Cloud Computing Interface (OCCI). It aims to provide a high-level interface for the integration of OCCI to other new or existing applications.
+pyssf is a collection of OCCI python modules. It aims to provide a high-level interface for the integration of OCCI to other new or existing applications.
Features:
---------
* It includes a REST API service with the OCCI specifications already implemented
-* It only requires a custom backend to interact with Cyclades
-* Being a python wsgi application, occi-py is easily deployed with Django or with its default web-server (tornado).
+* It only requires a custom backend and registry to interact with Cyclades
+
+Current progress
+=================
+By now we have considered implementing only the **Compute** backend of the OCCI to Cyclades/Openstack API bridge and we are planning to extend it for **networking** and **storage** capabilities.
+
+Installation
+-------------
+
+First, you need to install the required dependencies which can be found here:
+
+* `pyssf <https://code.grnet.gr/attachments/download/1182/pyssf-0.4.5.tar>`_
+* `kamaki <https://code.grnet.gr/projects/kamaki>`_
+
+Then you can install **snf-occi** API translation server by cloning our latest source code:
+
+* `snf-occi <https://code.grnet.gr/projects/snf-occi>`_
+
+**NOTE**: Before running setup.py you have to edit the **config.py** setting up:
+
+* API Server port
+* VM hostname naming pattern (FQDN providing the id of each compute resource)
+* VM core architecture
+
+Finally you can start the API translation server by running **snf-occi**
+
+Examples:
+---------
+For the examples below we assume server is running on localhost (port 8888) and authentication token is $AUTH. For the HTTP requests we are using **curl**.
+
+* Retrieve all registered Kinds, Actions and Mixins:
+
+ ::
+
+ curl -v -X GET localhost:8888/-/ -H 'Auth-Token: $AUTH'
+
+* Create a new VM described by the flavor 'C2R2048D20' and using the image 'Debian'
+
+ ::
+
+ curl -v -X POST localhost:8888/compute/
+ -H 'Category: compute; scheme=http://schemas.ogf.org/occi/infrastructure#; class="kind";'
+ -H 'X-OCCI-Attribute: occi.core.title = newVM' -H 'Category: C2R2048D20; scheme=http://schemas.ogf.org/occi/infrastructure#; '
+ -H 'Category: Debian; scheme=http://schemas.ogf.org/occi/infrastructure#;' -H 'Auth-Token: $AUTH'
+ -H 'Content-type: text/occi'
+
+* Retrieve all the details of th VM with identifier $ID
+
+ ::
+
+ curl -v -X GET localhost:8888/compute/$ID -H 'Auth-Token: $AUTH'
-Package on pypi: `OCCI 0.6 <http://pypi.python.org/pypi/occi/0.6>`_
+* Delete the VM with identifier $ID
+ ::
+
+ curl -v -X DELETE localhost:8888/compute/$ID -H 'Auth-Token: $AUTH'
Indices and tables