You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by na...@apache.org on 2018/02/06 10:38:43 UTC

jclouds-site git commit: Blog post about linking Nova and Neutron

Repository: jclouds-site
Updated Branches:
  refs/heads/nova-neutron [created] bd13a7ee8


Blog post about linking Nova and Neutron


Project: http://git-wip-us.apache.org/repos/asf/jclouds-site/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds-site/commit/bd13a7ee
Tree: http://git-wip-us.apache.org/repos/asf/jclouds-site/tree/bd13a7ee
Diff: http://git-wip-us.apache.org/repos/asf/jclouds-site/diff/bd13a7ee

Branch: refs/heads/nova-neutron
Commit: bd13a7ee8f1f6e6fdcc601c631e734300fdf08bb
Parents: b0c4f83
Author: Ignasi Barrera <na...@apache.org>
Authored: Tue Feb 6 11:38:19 2018 +0100
Committer: Ignasi Barrera <na...@apache.org>
Committed: Tue Feb 6 11:38:19 2018 +0100

----------------------------------------------------------------------
 README.md                         | 10 +++++---
 _layouts/home.html                |  2 +-
 _posts/2018-02-06-nova-neutron.md | 43 ++++++++++++++++++++++++++++++++++
 3 files changed, 51 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jclouds-site/blob/bd13a7ee/README.md
----------------------------------------------------------------------
diff --git a/README.md b/README.md
index b5d4c84..078a13f 100644
--- a/README.md
+++ b/README.md
@@ -2,9 +2,13 @@
 
 This repository supports the GitHub Pages site for jclouds. See and read more at [http://www.jclouds.org](http://www.jclouds.org).
 
+To test the site locally:
+
+    jekyll _1.5.1_ serve --safe
+
 To deploy the site:
 
-* ensure you have [jekyll](http://jekyllrb.com/docs/installation/) 1.5.1 installed
-* if necessary, clone this repository
-* run `sh ./deploy-site.sh [$uid] [$pwd]` from the repository root. Here, `$uid` is your ASF account ID and `$pwd` your ASF password. If you do not supply your account ID or password, you will be prompted for them
+* Ensure you have [jekyll](http://jekyllrb.com/docs/installation/) 1.5.1 installed
+* If necessary, clone this repository
+* Run `sh ./deploy-site.sh [$uid] [$pwd]` from the repository root. Here, `$uid` is your ASF account ID and `$pwd` your ASF password. If you do not supply your account ID or password, you will be prompted for them
 

http://git-wip-us.apache.org/repos/asf/jclouds-site/blob/bd13a7ee/_layouts/home.html
----------------------------------------------------------------------
diff --git a/_layouts/home.html b/_layouts/home.html
index b9e6a1b..c0b481f 100644
--- a/_layouts/home.html
+++ b/_layouts/home.html
@@ -40,7 +40,7 @@
             </div>
 
             <div id="keystonev3" class="alert alert-success">
-                <p>If you are an OpenStack user, read our <a href="/blog/2018/01/16/keystone-v3/">last blog post</a> about the <strong>OpenStack Keystone V3</strong> integration that will be released in jclouds <strong>2.1.0</strong>!</p>
+                <p>If you are an OpenStack user, read our blog posts about the <a href="/blog/2018/01/16/keystone-v3/">OpenStack Keystone V3</a> and <a href="/blog/2018/02/06/nova-neutron">OpenStack Nova and Neutron</a> integrations that will be released in jclouds <strong>2.1.0</strong>!</p>
             </div>
 
             <div id="releasenews" class="alert alert-info">

http://git-wip-us.apache.org/repos/asf/jclouds-site/blob/bd13a7ee/_posts/2018-02-06-nova-neutron.md
----------------------------------------------------------------------
diff --git a/_posts/2018-02-06-nova-neutron.md b/_posts/2018-02-06-nova-neutron.md
new file mode 100644
index 0000000..b9929a8
--- /dev/null
+++ b/_posts/2018-02-06-nova-neutron.md
@@ -0,0 +1,43 @@
+---
+author: <a href="https://twitter.com/IgnasiBarrera">Ignasi Barrera</a>
+comments: true
+date: 2018-02-06 07:00:00+00:00
+layout: post
+slug: nova-neutron
+title: OpenStack Nova and Neutron
+---
+
+One of the limitations of the jclouds implementation of the OpenStack Nova API is that is was not able to directly talk to the Neutron service. It used legacy security group APIs to manage access to instances, and there was no proper support for custom networking.
+
+Starting from Apache jclouds 2.1.0, an integration with OpenStack Neutron will be provided and users will be able to configure their Nova APIs to interact with a custom Neutron deployment.
+<!-- more -->
+
+To achieve this, users will be able to use the recent **context linking** feature, where APIs and providers that have dependencies between them can be *linked* so they can call each other where needed.
+
+## Linking OpenStack Nova to Neutron
+
+Links between APIs and providers are done at *context* level. This isolates each individual context and allows users to configure an independent set of properties for each one without overlapping issues. The `ContextLinking.linkContext` and `ContextLinking.linkView` helper methods can be used to easily link one context or view to another.
+
+The following example shows how to link an OpenStack Nova API to a Neutron API context, to leverage Neutron features when provisioning instances with Nova:
+
+{% highlight java %}
+// Create the connection to OpenStack Neutron
+ApiContext<NeutronApi> neutronCtx = ContextBuilder.newBuilder("openstack-neutron")
+   .endpoint("http://localhost/identity/v3/")
+   .credentials("domain:user", "password")
+   .overrides(neutronProperties)
+   .modules(ImmutableSet.of(new SLF4JLoggingModule()))
+   .build();
+
+// Create the connection to OpenStack nova and link it to Neutron
+NovaApi nova = ContextBuilder.newBuilder("openstack-nova")
+   .endpoint("http://localhost/identity/v3/")
+   .credentials("domain:user", "password")
+   .overrides(novaProperties)
+   .modules(ImmutableSet.of(
+               ContextLinking.linkContext(neutronCtx),
+               new SLF4JLoggingModule()))
+   .buildApi(NovaApi.class);
+{% endhighlight %}
+
+With this configuration the `nova` API is configured to use the linked `neutron` for all networking operations.