Edit Domain
Usage
edit domain $domain
Description
The command edit domain is used to modify a Virtual Domain record for REVLY. This command may be used to alter the parameters Group, Password, and Service.
Symbol
edit domain
Cardinal
action-identifier
Language
Domain Admin
Module
Admin
Parameters
ChangeDate
usage: changedate $timestamp
description: A Unix timestamp representing the last time the group record was modified.
default: Current timestamp
LDAP Suffix
usage: ldap suffix $ldapsuffix
description: The base search path of the LDAP tree.
default: revly
Change Group
usage: change group $group
description: Change the name of a group that this domain is a part of.
Change Password
usage: change password $password
description: Sets a password for the domain. This allows a domain administrator to login with the domain name as a username.
Add Service
usage: add service $service [$service etc..]
description: Add a service to the list of services that the domain will have access to.
Remove Service
usage: remove service $service [$service etc..]
description: Remove a service from the list of services that the domain will have access to.
Replace Service
usage: replace service $service [$service etc..]
description: Replace all services that the domain will have access to with the supplied service or services.
Actions
- Encrypt a new domain administrator password if provided.
- Generate a LDIF file containing the alterations to the domain record.
- Execute ldapmodify to edit the domain record in OpenLDAP.
Template
# Edit virtualDomain
dn: domain=:#DOMAIN#:,o=domains,dc=:#LDAP_SUFFIX#:
changetype: modify
[:#CHANGE_GROUP#:]
[:#CHANGE_PASSWORD#:]
[:#ADD_SERVICE#:]
[:#REMOVE_SERVICE#:]
[:#REPLACE_SERVICE#:]
replace: changeDate
:#CHANGE_DATE#:
Sub-Templates
changeDate: :#CHANGE_DATE#:
ChangeGroup
replace: group
:#GROUP#:
-
Group
group: :#GROUP#:
Change Password
replace: userPassword
:#PASSWORD#:
-
Password
userPassword: :#PASSWORD#:
Add Service
add: service
:#SERVICE#:
-
Remove Service
delete: service
:#SERVICE#:
-
Replace Service
replace: service
:#SERVICE#:
-
Service
service: :#SERVICE#:
Return Codes
Code | Human Readable Output |
---|---|
0 | Edited the domain '$domain'. |
1 | Could not edit the domain '$domain' because it does not exist. |
2 | Failed to add attributes to the domain '$domain' because one or more attributes already exists. |
3 | Failed to remove attributes from the domain '$domain' because one or more attributes does not exist. |
Example
Input
edit domain example.com change group "root" change password "secret" replace service email groupware im
Generated LDIF file
# Edit virtualDomain
dn: domain=example.com,o=domains,dc=revly
changetype: modify
replace: group
group: root
-
replace: userPassword
userPassword: {SSHA}GojpJiwrtz6zYKLyNa6nIoMy0GUS/LaYsgFSbA==
-
replace: service
service: email
service: groupware
service: im
-
replace: changeDate
changeDate: 1419358202
Output
Edited the domain 'example.com'.
Returncode
0