Tag Archives: appd

New vCAC & Application Services 6.1 template prep script (linux)

UPDATE: Dec 9 2014 – vCAC is renamed to vRealize Automation (vRA).   vRA 6.2 is dropping today and the pre-req script is posted here.

UPDATE: Dec 16 2014 – Doh!!  I was multitasking too much when i posted that last update.   The pre-req script wasn’t the point of this original post, but is still useful none the less.  To recap – the pre-req script is to ease setting up a vRA IAAS machine.   The template prep script is to ease setting up a linux template to be used _WITH_ vRA.
A great tool that flew under my radar in the most recent 6.1 release for AppD….er…Application Services and vCAC proper… is a script that does all the steps to prepare a linux template for you for both agents.   If you are at all familiar with this process, you’ll find it to be a huuuuuuuge time saver.

Original Post:
If you look at the documentation it’s quite cumbersome and full of potenial human error points.  This script will check all dependencies, install them where it can, and either prompt for the appropriate server names or accept inline input.


Getting Started
First pull the script off the AppD server and make it executable.

Snip20141106_22
How to use it – Interactive

If you wanted to just dive in run it for interactive mode:

Snip20141106_24
How to use it – Unattended

I update templates quite often in the lab environments I work in, so I like keeping a quick reference in a note that I can quickly cut & paste from.  Now that this script accepts inline inputs I could gain an extra sysadmin merit badge and just drop it into a shell script in a common place across all templates and just manually run that.  Easy Peasy.

So here’s the help page:

Snip20141106_23

Here’s what I would run which tells it the three server names, not to install java,  not to check ssl certs, a timeout of 300 secs and not to prompt to confirm:

The last line is a handy step that prevents centOS templates to increment the nic# when cloning.  There could be a better way but it works.

Snip20141106_25

… it does it’s thing…..and finishes with:

Snip20141106_26

 

Now you’re ready to shut it down, take a snapshot, start data collection, and update your blueprint!

Tagged , ,

Blog As A Service (Application Director + WordPress + Twitter + Cyclocross)

It has been a while since I’ve posted a full project, so here it goes.  Enjoy.  This time we have our first guest appearance in a super awesome software developer, cycling, and beer snob buddy @jrrickard, who I am doing a number of projects with these days & showcasing some of them in a booth at our employers internal Science Fair (It’s going to be rad.  And there will be pliny.)    How did I get so far off track already…

The Story

I have been doing a lot with VMware vCloud Application Director lately, and while I think it is a really interesting product that strokes all of my ex-sysadmin nerdy tendancies in all the right ways, I think it has a really bright future as it’s a _really_ powerful tool that almost no one knows about (yet).  So, I thought to myself, what’s something totally silly I can do with it while still showing off it’s real world potential?  (if you haven’t picked up on it yet, that’s kind of my thing…)   That’s when I decided:

 

About ten minutes later, I have this:

Screen Shot 2014-04-14 at 11.57.58 PM

 

So what’s going on here?   Step by Step:

1) I tweet a specific phrase like “I should start a blog on cyclocross” .

2) @jrrickard wrote some slick python that talks to Twitter over the REST API, finds that phrase, and sends a specially formatted call over a REST API to vCO [1] [note that is supposed to be a superscript… not sure how to do that and link to a lower section in this blog yet..]

3) The vCO workflow(s) talk to AppD over a REST API, processes the parameters, finds the application blueprint in AppD, and schedules the deployment.  (There is some new fancy secret sauce another co-worker is developing that I may post about at a later time.  In short it is a collection of workflows that finds and executes exactly what you want in AppD based on the human readable name instead of the ID… which is a pain in the rear to find..  seriously…)

4) The AppD blueprint that gets deployed is based on a canned blueprint found at the VMware Solution Exchange here [2] with only a minor addition at the end.  It deploys a CentOS VM from a template, and installs Apache, MySQL and WordPress in order with all dependencies resolved.  AppD configures each one and starts all services.

5) Based on the original tweet that started this whole mess, an AppD service I created from scratch and added to the blueprint (a) pulls a CLI for WordPress from Git, (b) uses that cli to write a few posts to the blog on the topic I tweeted, and lastly (c) goes to flickr (over another REST API) and pulls a bunch of images on the topic to adds them to the posts.

Screen Shot 2014-04-15 at 12.06.32 AM


Screen Shot 2014-04-15 at 12.07.15 AM

[FUTURE] 6) We didn’t add it in yet for a number of reasons, but plan to complete the loop and notify back with a tweet saying “Here’s your blog link!”.

More infos:

[1] So why make the REST call to vCO instead of AppD directly? 

Good question!   Doing it this way can be considered best practice because it can give you greater flexibility in processing all the data and lets you monitor the process and better trap erros. This way you are not relying on the 3rd party system entirely but can work around it and integrate better.

[2] VMware Solution Exchange?

Yes!  It’s great!  You can browse all of these canned & demo solutions like Websphere, Oracle, JasperReports, SharePoint, Jenkins, and Liferay to see how one could (or should) use AppD to automate deployments.

[3] Want to see the workflows and blueprints?

Maybe when I get some time to clean it all up. It’s kind of…messy right now.

Credits:

@jrrickard / Jeremy Rickard for the help with the python script running the twitter bot.

@MarcoCaronna  for the AppD/vCO zen master skills simplifying the REST API

BitNami for the original WordPress blueprint here

Tagged , , ,