Information
Unsupported content This version of the documentation is no longer supported. However, the documentation is available for your convenience. You will not be able to leave comments.

ServerGroup - addPermission


ServerGroup - addPermission

Description :

This command adds a permission entry to the ACL controlling access to a group. A permission consists of a role and an authorization.

Returns the DBKey of the server group.

This command works only on static server groups. For smart server groups, use the corresponding Group-addPermission with modelType 5007 (SMART_SERVER_GROUP).

You must call this command with a valid authorization name, role name, and server group name. Otherwise this command returns an error.

Valid authorizations for a server group are:

  • ServerGroup.Read
  • ServerGroup.Modify
  • ServerGroup.ModifyACL
  • ServerGroup.Delete
  • ServerGroup.Write
  • ServerGroup.*

Return type : DBKey

Command Input :

Variable Name

Variable Type

Description

groupName

String

The fully qualified name of the server group.

roleName

String

Name of the role.

authName

String

Name of the authorization.

Example

The following example shows how to add the permission consisting of the role "SampleRole" and the authorization "ServerGroup.Read" to a server group called "/Sample Group".

Script

ServerGroup addPermission "/Sample Group" SampleRole ServerGroup.Read

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

BMC Server Automation Command Line Interface 8.5