From: <rm...@hy...> - 2009-01-12 17:26:27
|
Author: rmorgan Date: 2009-01-12 09:26:18 -0800 (Mon, 12 Jan 2009) New Revision: 12229 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=12229 Modified: trunk/src/org/hyperic/hq/hqu/rendit_sys/metaclass/ResourceCategory.groovy Log: Allow server installpath and description to be set during resource creation. Modified: trunk/src/org/hyperic/hq/hqu/rendit_sys/metaclass/ResourceCategory.groovy =================================================================== --- trunk/src/org/hyperic/hq/hqu/rendit_sys/metaclass/ResourceCategory.groovy 2009-01-12 16:55:34 UTC (rev 12228) +++ trunk/src/org/hyperic/hq/hqu/rendit_sys/metaclass/ResourceCategory.groovy 2009-01-12 17:26:18 UTC (rev 12229) @@ -493,8 +493,19 @@ Platform platform = toPlatform(parent) ServerValue sv = new ServerValue() sv.name = name - sv.description = "desc: ${name}" - sv.installPath = 'dummy install path' + + if (cfg['installpath']) { + sv.installPath = cfg['installpath'] + } else { + sv.installPath = "" + } + + if (cfg['description']) { + sv.description = cfg['description'] + } else { + sv.description = "" + } + def res = svrMan.createServer(subject, platform.id, proto.instanceId, sv).resource setConfig(res, cfg, subject) |