Log Message:
-----------
First implementation of the getUserData command in the AwsEc2Util module.
Tracker#: https://sourceforge.net/tracker/?func=detail&aid=3362030&group_id=151079&atid=779850
Added Paths:
-----------
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/bin/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/commands/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/commands/getUserData.xml
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/lib/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/lib/command.xml
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/objects/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/templates/
controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/type.xml
Added: controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/commands/getUserData.xml
===================================================================
--- controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/commands/getUserData.xml (rev 0)
+++ controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/commands/getUserData.xml 2011-07-10 17:14:25 UTC (rev 2291)
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+ Command Module: AwsEc2Util
+ Command Name: getUserData
+ Command Template: com/controltier/shared/convert/AntCommand.template.xml
+ Description: Gets the AWS EC2 instances's user data
+ Author:
+ Created: Sun Jul 10 12:34:50 EDT 2011
+-->
+<project name="getUserData" default="execute">
+ <description>Gets the AWS EC2 instances's user data</description>
+ <property name="command.name" value="getUserData"/>
+ <import file="${module.dir}/lib/command.xml"/>
+ <!--
+ -execute - Runs the handler implementation
+ -->
+ <target name="-execute" description="Runs the handler implementation">
+ <!--Generator: com.controltier.shared.convert.TypeXMLHandlerGenerator-->
+ <!--NOTE: -execute target content is auto-generated by the handler generation process. -->
+ <tempfile property="userDataPropertyFile" destdir="${opts.destdir}" prefix="userdata." suffix=".properties" deleteonexit="true"/>
+ <get src="${opts.userdataurl}" dest="${userDataPropertyFile}"/>
+ <property file="${userDataPropertyFile}" prefix="ec2InstanceUserData"/>
+ <echoproperties prefix="ec2InstanceUserData"/>
+ </target>
+ <target name="-getopts" depends="-pre-opts">
+ <!--NOTE: -getopts target and content is auto-generated by the handler generation process. -->
+ <get-opts failonerror="true" usageProperty="getopts.usage" errorProperty="getopts.error" optsValue="${cmd.line}">
+ <opts>
+ <opt parameter="userdataurl" description="URL to access user data" required="false" property="opts.userdataurl" type="string" default="http://169.254.169.254/latest/user-data"/>
+ <opt parameter="destdir" description="destination directory for the user data" required="false" property="opts.destdir" type="string" default="${framework.var.dir}/tmp"/>
+ </opts>
+ </get-opts>
+ </target>
+</project>
Added: controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/lib/command.xml
===================================================================
--- controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/lib/command.xml (rev 0)
+++ controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/lib/command.xml 2011-07-10 17:14:25 UTC (rev 2291)
@@ -0,0 +1,8 @@
+<?xml version="1.0"?>
+<!--
+Module: Deployment
+Revision: $Revision: 8652 $
+-->
+<project default="execute">
+ <import file="${modules.dir}/Module/lib/command.xml"/>
+</project>
Added: controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/type.xml
===================================================================
--- controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/type.xml (rev 0)
+++ controltier/branches/controltier-3-6-support/aws/modules/AwsEc2Util/type.xml 2011-07-10 17:14:25 UTC (rev 2291)
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+This document is used to define one or more Types.
+For reference, see: http://controltier.org/wiki/Type-v10.xml
+-->
+<types
+ xmlns:module="http://open.controltier.com/base/Modules#"
+ xmlns:type="http://open.controltier.com/base/Types#"
+ xmlns:cmd="http://open.controltier.com/base/Modules/Commands#">
+
+ <!-- The type element defines a Type and command module. -->
+ <type
+ name="AwsEc2Util"
+ role="concrete"
+ uniqueInstances="true">
+
+ <!-- description of the Type -->
+ <description>AWS EC2 utility module</description>
+
+ <supertype>
+ <!-- supertype/typereference: defines the supertype of the Type -->
+ <typereference name="Module"/>
+ </supertype>
+
+ <command-settings>
+ <!-- command-settings: properties of the command module -->
+ <!-- See Wiki: -->
+ <!-- http://controltier.org/wiki/Type-v10.xml#command-settings -->
+ <notification notify="false"/>
+ <template-directory></template-directory>
+ <dependency-view parents="false" children="true" proximity="1"/>
+ <logger name="AwsEc2Util"/>
+ </command-settings>
+
+
+ <attributes>
+ <!-- Define attributes of the Type here -->
+ <!-- See Wiki: -->
+ <!-- http://controltier.org/wiki/Type-v10.xml#attributes -->
+
+ </attributes>
+
+ <constraints>
+ <!-- Define constraints of the Type here -->
+ <!-- See Wiki: -->
+ <!-- http://controltier.org/wiki/Type-v10.xml#constraints -->
+
+ </constraints>
+
+ <commands>
+ <!-- Define commands here -->
+ <!-- See the Documentation on the ControlTier Wiki: -->
+ <!-- http://controltier.org/wiki/Type-v10.xml#commands -->
+
+ <command name="getUserData" description="Gets the AWS EC2 instances's user data" command-type="AntCommand" is-static="true">
+ <implementation>
+ <tempfile property="userDataPropertyFile" destdir="${opts.destdir}" prefix="userdata." suffix=".properties" deleteonexit="true"/>
+ <get src="${opts.userdataurl}" dest="${userDataPropertyFile}"/>
+ <property file="${userDataPropertyFile}" prefix="ec2InstanceUserData"/>
+ <echoproperties prefix="ec2InstanceUserData"/>
+ </implementation>
+ <opts>
+ <opt parameter="userdataurl" description="URL to access user data" required="false" property="opts.userdataurl" type="string" default="http://169.254.169.254/latest/user-data"/>
+ <opt parameter="destdir" description="destination directory for the user data" required="false" property="opts.destdir" type="string" default="${framework.var.dir}/tmp"/>
+ </opts>
+ </command>
+ </commands>
+
+ </type>
+
+ <!--
+ Multiple <type> elements are allowed.
+ -->
+</types>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.