Java Reference
In-Depth Information
Launching the CLI
If you are using Windows, you can start the CLI by entering the following command from
the JBOSS_HOME/bin folder using the Command Prompt:
jboss-cli.bat
Alternatively, enter the following command if you are using Linux:
./jboss-cli.sh
Once the CLI has started, you can connect to the managed server instance using the con-
nect command, which by default connects to localhost and the 9990 port:
[disconnected /] connect
[standalone@localhost:9990 /]
If you want to connect to another address or port, you can simply pass it to the connect
command, as follows:
[disconnected /] connect 192.168.1.1
[standalone@192.168.1.1:9990 /]
It is also possible to launch a CLI in the connected mode; this allows it to be connected
automatically and to possibly specify the commands to be executed. For example, the fol-
lowing shell command automatically connects to a WildFly instance and issues a
shutdown command:
> jboss-cli.bat --connect command=:shutdown
{"outcome" => "success"}
CLI is especially useful for the automation of your software development pro-
cess— Continuous Integration ( CI ) and production environment management systems can
automatically control the life cycle of your application server with tools such as Chef ( ht-
tps://www.getchef.com/ ) or Puppet ( http://puppetlabs.com/ ) . It might be handy if you
would like to minimize the number of manual tasks that are required to be done to deploy
an application.
Search WWH ::




Custom Search