1 Pictl
verita84 edited this page 2020-12-18 16:03:25 +00:00

Pictl is a bash client to easily control the cluster. It will make all the HTTP requests using curl.

The following variables need to be set in the file:

server - IP address of the server
port - PORT that the server uses
token - The token used in the Server and Agent configs.

If a command has arguments ([image] or [container]), the commands will run cluster-wide. For example if you run "pictl delete" without specifying a container, all of the containers will be deleted.

To get a list of accepted arguments:

pictl

To get a list of all the nodes in PiCluster:

pictl nodes

To build a Docker image from the config:

pictl build [image]

To create and start a container from the config:

pictl create [container]

To stop a container from the config:

pictl stop [container]

To delete a container from the config:

pictl delete [container]

To restart a container from the config:

pictl restart [container]

To execute a command on all of the hosts

pictl exec "command"

Display all of the Docker images on each host

pictl images

To view the current log

pictl log