A new set of rake tasks has been created to manage users, groups, shares and nodes. For Shares version 1.8 and earlier, see install instructions below.

Note: Square brackets in usage statements denote optional arguments and should not be included when running the commands.

Function: Create and Modify User

To modify a user simply change the values as needed.

Syntax

Usage: rake data:user:create -- --username %username% --password %password% --email %email%

Example

bundle exec rake data:user:create -- --username jay --password aspera --email test@asperasoft.com

Function: Delete User

Syntax

Usage: rake data:user:delete -- --username %username%

Example

bundle exec rake data:user:delete -- --username test

Function: Export List of Users to Standard Out of CSV File

Arguments

  • --csv or -c - flag that specifies that the users should be exported to a csv file.
  • --path or -p - the path to the target directory. Does not include file_name. Default value is the current directory.
  • --file_name or -f - the name of the resultant csv file. If not provided, the file will be called users.csv.

Syntax

Usage: rake data:user:export -- [--csv --path --file_name]

Example to Print to Standard Out

bundle exec rake data:user:export

Example to Save to CSV File

bundle exec rake data:user:export -- --csv --path /tmp --file_name users.csv

Function: Import Users from a CSV File

Imports users from a .csv file. The users’ information must be in the form of: Username, First Name, Last Name, Email, Password. If no password is provided, a randomly generated password will be set, and the user wil have to reset the password with the forgot password link.

Arguments

  • --path or -p - the path of the csv file for import.

Syntax

Usage: rake data:user:import -- --path %csv path%

Function: Export List of Groups to File

Arguments

  • --path or -p - the path to the target directory. Does not include file_name. Default value is the current directory.

Syntax

Usage: rake data:group:export -- --path /path/to/file

Function: Import Groups from a File

Imports groups from a file. If the group already exists in Shares, the rake task does not add the group.

Arguments

  • --path or -p - the path of the file for import.

Syntax

Usage: rake data:group:import -- --path /path/to/file

Function: Create Group

Syntax

USAGE: rake data:group:create -- --group_name %group_name%

Example

bundle exec rake data:group:create -- --group_name users

Function: Delete Group

Syntax

USAGE: rake data:group:delete -- --group_name %group_name%

Example

bundle exec rake data:group:delete -- --group_name users

Function: Add User to Group

Syntax

USAGE: rakedata:group:user:add -- --username %username% --group_name %group_name%

Example

bundle exec rake data:group:user:add -- --username test --group_name users

Function: Delete User from Group

Syntax

USAGE: rake data:group:user:delete -- --username %username% --group_name %group_name%

Example

bundle exec rake data:group:user:delete -- --username test --group_name users

Function: Create and Modify a Share

To modify a share simply change the values as needed.

Syntax

Usage: rake data:share:create -- --node_name %node_name% --share_name %share_name% --directory %directory%

Example

rake data:share:create -- --node_name aspera --share_name share1 --directory /mnt

Function: Delete a Share

Syntax

Usage: rake data:share:delete -- --share_name %share_name%

Example

rake data:share:delete -- --share_name test_share

Function: Manage User's Share Permissions

Permissions

  • browse_permission
  • download_permission
  • upload_permission
  • mkdir_permission
  • delete_permission
  • rename_permission,content_availability_permission
  • and manage_permission

Syntax

Usage: rake data:user:share_permissions -- --username %username% --share_name %share_name% [--%DESIRED PERMISSION% %true or false% --%DESIRED PERMISSION% %true or false% ...]

Example

bundle exec rake data:user:share_permissions -- --username test --share_name share_example --upload_permission true --mkdir_permission true

Function: Manage Group's Share Permissions

Permissions

  • browse_permission
  • download_permission
  • upload_permission
  • mkdir_permission
  • delete_permission
  • rename_permission,content_availability_permission
  • and manage_permission

Syntax

Usage: rake data:group:share_permissions -- --groupname %groupname% --share_name %share_name% [--%DESIRED PERMISSION% %true or false% --%DESIRED PERMISSION% %true or false% ...]

Example

bundle exec rake data:group:share_permissions -- --groupname test --share_name share_example iiupload_permission true --mkdir_permission true

Function: Create and Modify a Node

To modify a Node simply change the values as needed.

Syntax

Usage: rake data:node:create -- --name %name% --host %host% --api_username %api_username% --api_password %api_password%

Example

bundle exec rake data:node:create -- --name Storage --host localhost --api_username xfer --api_password p@zzword

Function: Delete a Node

Syntax

Usage: rake data:node:delete -- --name %name%

Example

bundle exec rake data:node:delete -- --name Storage

Function: Add and Configure LDAP

Acceptable directory types are: ActiveDirectory, OpenDirectory, FedoraDirectoryServer, and OpenLdap. Acceptable authentication methods are anonymous and simple (bind requires a username and a password). Acceptable encryption types are unencrypted (default) and simple_tls.

Syntax

Usage: rake data:ldap_config -- --directory_type %directory_type% --name %name% [--description %description%] --host %host% --port %port% [--base_dn %base_dn%] --authentication_method %authentication_method% [--username %username% --password %password% --encryption %encryption%]

Example

rake data:ldap_config -- --directory_type ActiveDirectory --name test_dir --host dev.aspera.us --port 636 --base_dn OU=Asperasoft,DC=dev,DC=aspera,DC=us --authentication_method simple --username adbinddev --password PASSWORD --encryption simple_tls

Function: Configure Web Server Settings

Syntax

Usage: rake data:web_server -- --host %host% --port %port% --tls %tls%

Example

rake data:web_server -- --host example.web.host --port 1234 --tls true

Function: Configure SMTP Server Settings

The first time this rake task is ran, it will create a new entry and will require all of the fields. From this point on, it will only modify the specified fields and will leave the non-specified fields the same.

Syntax

Usage: rake data:smtp_server -- --server %server% --port %port% --domain %domain% --tls %tls% --username %username% --password %password% --from %from%

Example

Usage: rake data:smtp_server -- --server some_server --port 1234 --domain some_domain --tls true --username dchan --password aspera --from test@asperasoft.com

Function: Configure Manager Permissions

Syntax

Usage: rake data:manager_config -- --UI %ui% --API %api%

Example

rake data:manager_config -- --UI true --API false
Video player

Video

×