|
Key
This line was removed.
This word was removed. This word was added.
This line was added.
|
Changes (6)
View Page Historyh3. Interacting with several Petals node without exiting Petals CLI
In interactive mode or script mode, we should be able to close a connection and open another one without leaving Petals CLI. This is done by commands 'close' and 'open'. If no arguments are set on command 'open', default values (localhost:7700, login=petals, pwd=petals) are used:
{code}
> ./petals-cli.sh -C
> ./petals-cli.sh -C
------------------------------------------------------------------------------
petals-cli> open <user1>:<password1>@<host1>:<port1>
petals-cli> open <user1>:<password1>@<host1>:<port1>
Conected on <host1>:<port1> with '<user1>'
petals-cli> close
petals-cli> open <user2>:<password2>@<host2>:<port2>
Conected on <host2>:<port2> with <user2>
Conected on localhost:7700 with 'petals'
{code}
h3. Default connection
By default (if no arguments or option are set):
- In mode 'console', the connexion is establish on command 'open' to localhost:7700 with credentials 'petals/petals',
{code}
> ./petals-cli.sh -C
Type 'help' for help.
------------------------------------------------------------------------------
petals-cli> open
Conected on localhost:7700 with 'petals'
{code}
- In mode 'command line', connexion parameter are mandatory
{code}
> ./petals-cli.sh -h <host> -n <port> -u <user> -p <password> -c <command>
{code}
- In mode 'script', the connexion is establish on command 'open' to localhost:7700 with credentials 'petals/petals'
{code}
> ./petals-cli.sh -f - << EOF
open
EOF
{code}
By default (if no arguments or option are set):
- In mode 'console', the connexion is establish on command 'open' to localhost:7700 with credentials 'petals/petals',
{code}
> ./petals-cli.sh -C
Type 'help' for help.
------------------------------------------------------------------------------
petals-cli> open
Conected on localhost:7700 with 'petals'
{code}
- In mode 'command line', connexion parameter are mandatory
{code}
> ./petals-cli.sh -h <host> -n <port> -u <user> -p <password> -c <command>
{code}
- In mode 'script', the connexion is establish on command 'open' to localhost:7700 with credentials 'petals/petals'
{code}
> ./petals-cli.sh -f - << EOF
open
EOF
{code}
h2. Petals CLI commands