users
๐ก
All users
commands require a connection to a Relay database.
This must be configured when running these commands.
add
Add a new user to the Database, generates a password, and creates a Sub Node for them.
Command
add <USERNAME>
: Add a new User with the specified username
Usage Scenarios
Add a User and Sub Node for a Bunny instance
Command
users add my-bunny
Output
โโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Username โ Password โ Collection ID โ
โโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ my-bunny โ 2WgSShhPps7plNnt โ 0194ac94-a025-7f7e-8ec1-a26f29c73bdf โ
โโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
reset-password
Generate a new password for an existing user.
Command
reset-password <USERNAME>
: Generate a new password for the User with the specified username
Usage Scenarios
Add a User and Sub Node for a Bunny instance
Command
users reset-password my-bunny
Output
โโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโ
โ Username โ Password โ
โโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโค
โ my-bunny โ 2WgSShhPps7plNnt โ
โโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโ
list
List all usernames in the Database.
Command
list
: List all usernames in the database
Usage Scenarios
List all usernames in the database
Command
users list
Output
โญโUsersโโโโโโโโโโฎ
โ my-bunny โ
โ my-sub-relay โ
โ another-bunny โ
โฐโโโโโโโโโโโโโโโโฏ
list-subnodes
List all subnodes associated with a username in the Database.
Command
list-subnodes <USERNAME>
: List all subnodes associated with a username in the Database
Usage Scenarios
List all subnodes associated with a username in the Database
Command
users list-subnodes my-bunny
Output
โญโSubNodes for User: my-bunnyโโโโโโโโโโโฎ
โ 01954c60-8d3f-7816-b81a-f270f44bc79b โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
add-subnode
Create a new subnode associated with an existing user.
Command
add-subnode <USERNAME> [OPTIONS...]
: Create a new subnode associated with an existing user
Options
--yes
,-y
: Automatically skip the final confirmation, responding withy
.
Usage Scenarios
Create a new subnode associated with an existing user
Command
users add-subnode my-bunny
Output
โโ Summary โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Selected user: my-bunny
A new subnode will be created for this user.
Do you want to proceed? [y/n] (n): y
โโ Results โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โญโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ Username โ New Collection ID โ
โโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ my-bunny โ 01954d72-4e35-7ade-a727-63d5e113e901 โ
โฐโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
remove-subnodes
Remove one or more subnodes associated with an existing user.
Command
remove-subnodes <USERNAME> [<SUBNODE IDS>...] [OPTIONS...]
: Remove one or more subnodes associated with an existing user
Options
--yes
,-y
: Automatically skip the final confirmation, responding withy
.--all
: Remove ALL subnodes associated with the user, instead of specifying IDs.--empty-user <keep|remove>
: explicitly specify whether tokeep
orremove
a User who has had all their subnodes removed. If omitted, the cli will prompt interactively in the case of an empty user.
Usage Scenarios
Remove a single subnode from a User with more than one subnode.
Command
users remove-subnodes my-bunny 01954d72-4e35-7ade-a727-63d5e113e901
Output
โโ Summary โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Selected user: my-bunny
โญโSubNodes to removeโโโโโโโโโโโโโโโโโโโโฎ
โ 01954d72-4e35-7ade-a727-63d5e113e901 โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
Do you want to proceed? [y/n] (n): y
โโ Results โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โญโRemoved SubNodes for User: my-bunnyโโโฎ
โ 01954d72-4e35-7ade-a727-63d5e113e901 โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
Remove two subnodes from a User with only two subnodes, but keep the user afterwards
Command
users remove-subnodes my-bunny -y --empty-user keep 01954c60-8d3f-7816-b81a-f270f44bc79b 01954d7b-dadf-77a3-9e78-0d83dd3f4c6e
Note that the options need to go before the list of subnode IDs, otherwise the CLI canโt differentiate between what is a cli argument and what is intended to be a subnode ID.
Output
โโ Summary โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Selected user: my-bunny
โญโSubNodes to removeโโโโโโโโโโโโโโโโโโโโฎ
โ 01954d7b-dadf-77a3-9e78-0d83dd3f4c6e โ
โ 01954c60-8d3f-7816-b81a-f270f44bc79b โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
The Empty User will not be removed
โโ Results โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โญโRemoved SubNodes for User: my-bunnyโโโฎ
โ 01954d7b-dadf-77a3-9e78-0d83dd3f4c6e โ
โ 01954c60-8d3f-7816-b81a-f270f44bc79b โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
โน The Empty User was not removed.
Delete all subnodes and the associated user
Note that this can also be used to delete an empty user with no sub nodes.
Command
users remove-subnodes my-bunny --all --empty-user remove -y
Output
โโ Summary โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Selected user: my-bunny
ALL SubNodes will be removed
The Empty User will be removed
โโ Results โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โน The Empty User was removed.
Last updated on