Looking To Live in France ?

Thought we would give you a preview of our home here in Brittany, western France.

If you seek the quiet life with a possible opportunity to provide local temporary accommodations, then look here: http://fabulousbrittanyhome.fr/


Enjot the french life-style here in Brittany, France

Wonderfully large home for your family or a football team :-D

Asciidoctor Admonition Icons Missing

Been writing some reference documents in my new ‘best friend’ – the asciidoctor markup syntax. For some time now i get puzzled when i want an admonition icon to appear in my document but it won’t. Ok my markup looks good to me and i have installed the ruby asciidoctor version:

jnorthr@jnorthr-EC548AA-ABU-a1128-uk:~/Desktop$ asciidoctor -V
Asciidoctor 0.1.4 [http://asciidoctor.org]

So a typical document like this works fine except that the beautiful image icons do not show up. I thought at first i had to lug around a folder of ./images/icon/*.png and all that stuff but it irked me somewhat.

My text of

= Notes About Asciidoc Sample Applications
jnorthr <jim.northrop@orange.fr>
v1.0, 2014-06-01 updated 7 June 2014

:icons: font

NOTE: Asciidoctor now supports font-based admonition icons, powered by Font Awesome!

== Overview

Caelyf lacks a template servlet for markup documents written using the asciidoctor markup syntax.

== Sample Application

You can find most of our sample applications on our github anynines account at https://github.com/anynines/[https://github.com/anynines/]. 

WARNING: You will need to signup with a cloud foundry PaaS provider before running any of these samples.

looks ok and renders as html quite nicely.



So that’s not what i need is it ? Where are my awesome icons ? Well, it turns out that i needed to add a bit of code to pull down the awesome.css stylesheet that has all the magic. So on the line just above

:icons: font

I added a passthru comment that renders in the final html document. That passthru comment looks like:


v1.0, 2014-06-01 updated 7 June 2014

<link rel="stylesheet"  href="http://cdnjs.cloudflare.com/ajax/libs/font-awesome/3.1.0/css/font-awesome.min.css">

:icons: font

So we need an external css link specification between the document date line and the icons font line. See my <LINK code above, and yes you do need to include ++++ lines above and below it too.

If you put that line into your .adoc script, so should experience the joy and pleasure of visible awesome fonts for all asciidoctor admonitions !   :)



Gradle Properties in Cloud Foundry Closure

See notes here: https://github.com/cloudfoundry/cf-java-client/blob/master/cloudfoundry-gradle-plugin/README.md

1. according to gradle documentation, we can put our PaaS cloud foundry target credentials into


like this:


with single quotes. If we do that, we get this result:

 Authenticating to 'https://api.run.pivotal.io' with username ''men@work.com''
 POST request for "https://login.run.pivotal.io/oauth/token" resulted in 401 (Unauthorized); invoking error handler
 :template-project:cf-login FAILED

FAILURE: Build failed with an exception.

but removing the single quotes makes it work.

NOTE: Gripe !! the credentials in gradle.properties take precedence over those declared in our gradle script closure !!! So if we deploy the same app to several different PaaS targets we can not declare credentials in gradle.properties we just need a build.gradle script for each PaaS target  :-P

2. plugin cf-push where there is already an existing service leaves orphan services that were originally attached. Is this because of the “rediscloud-${randomWord}” random word declaration in the cloud foundry closure ?
3. same as 2. but also looses the uri as there is no/or a faulty rebind of uri to our app


4. cf-push of new app that does not already exist appears to work, correctly builds services and binds the uri correctly.


5. also note that ~/.gradle/gradle.properties needs a password too, so:


For Our Beautiful Friends@Anynines.com


Hi Guys and Dolls !

Just a note to say a GR8 BIG Thank You to each and everyone of you and all your clever crew too – thanx for all your super efforts on the Anynines PaaS project! It’s such a pleasure to work with a solid reliable platform like Anynines.com

I have been surprised that Anynines is not more widely known across the vast internet. To improve that situation, wanted to make a nice introductory tutorial. It could help new users ease their way onto Anynines.

With the kind help of Floor, who provided html color codes and font choices used on Anynines, it was possible to create something that looks (almost) like a native Anynines page.

It’s been some time in the making and it was so much fun too ! Am not worried if you all think it is useless or unnecessary – we can bin it – no worries. Alternatively if you think it might be useful or if you have any ideas or suggestions, or we need to add other topics, then send me some ideas. I’ll put it up on my github acct when it’s finished, so you can clone from there into your own account.

You can always rename it, but as i like george harrison’s album, i’ve nicknamed our tut ‘cloud9:-)

So enjoy: http://cloud9.de.a9sapp.eu


( The zip file example is not available yet as i dont have enough resource for that )

Again, thanx for the pleasure !

kind regards


PS – yes i know this tut was for CF v5 and we’ll need to update to CF v6 samples – you were too quick!!! :-}

Gradle Plugin for Cloud Foundry for IBM Blue Mix

IBM came late to the PaaS party. Perhaps it was a tactical choice to avoid Cloud Foundry version one. Their delay allowed the cloud foundry platform to evolve so now, with IBM Blue Mix, we have a quick performing version two of cloud foundry.

To use version one of C/F we had to use command line tools like VMC and CF v5.4.7. For V2, we need more modern command line tools like the recently introduced CF ver. 6 which is written in the GO programming language. It avoids the need for a Ruby programming installation as the GO version of CF carries all it’s own logic as a single bundle. Hurrah ! I use CF v6.0.2 to talk to Blue Mix.

But as i am still looking for better ways to deploy apps to cloud foundry platforms, i like to use a build tool and, as i’ve reported in prior posts, the gradle build tool is my current flavor of the month. With it, we can get plugin components that do much of the work and add new pieces of functionality.

So for my gradle build scripts, i’ve picked up on the cloud foundry plugin for gradle. Scott Frederick explains it in more detail here if you have a need to know.

Back to IBM’s Blue Mix. Here is part of my gradle build script to deploy an app to IBM’s Blue Mix platform. We need to declare the plugin we need and the location where it can be downloaded from, so :


import org.apache.ivy.plugins.resolver.URLResolver
apply plugin: 'cloudfoundry'
buildscript {
 repositories {
 maven { url "https://oss.sonatype.org/content/repositories/springsource-milestones" }
 dependencies {
 classpath group: 'org.cloudfoundry', name: 'cf-gradle-plugin', version: '1.0.2'

Notice that i’ve picked v1.0.2 as this version WILL talk to later cloud foundry v2 platforms. To reach  the earlier version one platforms, we use v1.0.0 of this plugin.

Next we need to declare some values inside the closure used by this plugin.  In particular, the target API address needs to be https://api.ng.bluemix.net, for your username and password values, put in the ones you used to join IBM’s beta plan for Blue Mix. Or do so here.

Then pick the name your want your app to be. Fill that name into the application field below and repeat it in the URI in place of my caelyftemplate2 choice. The full closure looks like this :

cloudfoundry {
 space = 'dev'
 username = 'men@work.com'
 password = '******'
 file = new File('build/libs/template-project-1.2.0.war')
 uri = 'http://caelyftemplate2.ng.bluemix.net'
 application = 'caelyftemplate2'

and that should do it. I’m deploying a war file from within my gradle build folder. You might need to change the new File(‘xxx’) choice to point to your own war file.

Wrap the above text into a build.gradle text file. You need an installed gradle build tool from http://www.gradle.org/

To see what cloud foundry commands we have from the plugin, we can do a ‘tasks’ request to show them. Here is a sample output on my system from such a command:

jim@a1128-uk:/media/jim/project$ bash gradlew -b gradle.build tasks
 Parallel execution is an incubating feature.
 All tasks runnable from root project
Build Setup tasks
 init - Initializes a new Gradle build. [incubating]
 wrapper - Generates Gradle wrapper files. [incubating]
Cloud Foundry tasks
 cf-app - Displays information about the application deployment
 cf-apps - Lists applications running on the targeted Cloud Foundry platform
 cf-bind - Binds services to an application
 cf-create-service - Creates a service, optionally binding it to an application
 cf-delete - Deletes an application deployment
 cf-delete-service - Deletes a service
 cf-deploy - Deploys a variants of an application
 cf-env - List application environment variables
 cf-login - Logs in to the target Cloud Foundry platform
 cf-logout - Logs out of the target Cloud Foundry platform
 cf-logs - Shows the contents of log files
 cf-map - Maps a URI to an application
 cf-push - Pushes an application
 cf-restart - Restarts an application
 cf-scale - Scales application instances up or down
 cf-service-plans - Displays information about service offerings
 cf-services - Displays information about service instances
 cf-set-env - Sets environment variables to an application
 cf-spaces - Displays available spaces
 cf-start - Starts an application
 cf-stop - Stops an application
 cf-swap-deployed - Swaps the URIs for deployed variants of an application
 cf-target - Displays information about the target Cloud Foundry platform
 cf-unbind - Unbinds services from an application
 cf-undeploy - Undeploys variants of an application
 cf-unmap - Unmaps a URI from application
 cf-unset-env - Deletes environment variables from an application
Help tasks
 dependencies - Displays all dependencies declar
ed in root project 'template-project'.
 dependencyInsight - Displays the insight into a specific dependency in root project 'template-project'.
 help - Displays a help message
 projects - Displays the sub-projects of root project 'template-project'.
 properties - Displays the properties of root project 'template-project'.
 tasks - Displays the tasks runnable from root project 'template-project'.
To see all tasks and more detail, run with --all.


Total time: 31.991 secs

You can see one of the deployment commands. The CF-PUSH task asks gradle to deploy an app to BlueMix.

First, you need to login before running the CF-PUSH command, so do CF-LOGIN which uses your credentials from within the closure.

Make sure you change directories into the folder with the above build.gradle script. Then from a command line, try this:

gradle cf-login cf-push

This command asks the gradle build tool to issue a login to the BlueMix platform at the defined target using the credentials from within the closure. As i’m using Lubuntu Linux 14.04, i need to call the ‘bash’ tool  my command looks like this (apple/windoze people won’t need bash):

jim@a1128-uk:/media/jim/project$ bash gradle -b build.gradle cf-login cf-push
Parallel execution is an incubating feature.
Authenticating to 'https://api.ng.bluemix.net' with username 'men@work.com'
Authentication successful
Updating application caelyftemplate2
Uploading build/libs/template-project-1.2.0.war
Starting caelyftemplate2
-----> Downloaded app package (34M)
-----> Downloaded app buildpack cache (4.0K)
Buildpack Version: 20140425-1807
-----> Downloading IBM 1.7.0 JRE from http://file.icap.cdl.ibm.com/icapShared/jre/ibm-java-jre-7.0-6.0-linux-x86_64-small-footprint-uncompressed-jar-20140116.tar.gz (0.0s)
 Expanding JRE to .java (1.1s)
Downloading from output/wlp/com.ibm.ws.liberty-2014.3.0.0-201404251807.tar.gz ... (0.0s).
Installing archive ... (0.6s).

-----> Uploading droplet (126M)

Checking status of caelyftemplate2
 1 of 1 instances running (1 running)
Application caelyftemplate2 is available at http://http://caelyftemplate2.ng.bluemix.net


Total time: 2 mins 58.293 secs

That’s enough for the moment. If i get a mo. i’ll post a small gradle project that has all this in it. Ok now, go forth and hack !  :)