Skip to content

object operations

Ryan Newington edited this page Jun 6, 2016 · 1 revision

<object-operations> element

The SSH MA allows custom commands to be defined for each operation against an object. The <object-operations> element contains the definition of the operations and their commands.

The <object-operations> element must contain the following attributes

XML Attribute Description Allowed Values
object-class The class of object that the contained operations apply to Any object class defined in the MA schema
The following object operations are supported by this MA

As a minimum, a FullImport operation must be defined for each object type. The <object-operations> element supports one or more <object-operation> elements.

Example

<object-operations object-class="user">
    <object-operation xsi:type="sshma:object-operation-ExportAdd">
        <commands>
            <command>/usr/local/bin/sudo /usr/sbin/useradd {dn:$1}</command>
        </commands>
    </object-operation>
</object-operations>

<object-operations object-class="group">
    <object-operation xsi:type="sshma:object-operation-ExportAdd">
        <commands>
            <command>/usr/local/bin/sudo /usr/sbin/groupadd {dn:$1}</command>
        </commands>
    </object-operation>
</object-operations>

In the example above, an ExportAdd command calls the useradd command on a target system to create a new user.

Clone this wiki locally