Appendix: QNX Container Manager Client Utility (qcmctl)
Commands
The command hierarchy of the qcmctl organizes into three sub-commands: image, pod, and container.
The structure of the commands is designed to closely resemble the APIs of the qcmgr resource manager interface.
# use qcmctl
qcmctl - QNX Container Manager Client Tool
Usage:
qcmctl COMMAND SUBCOMMAND
Commands:
help
image
pod
container
Image Subcommands:
help
pull
import
list
status
remove
Pod Subcommands:
help
create
list
status
remove
Container Subcommands:
help
create
list
start
status
stop
remove
exec
logs
Run 'qcmctl COMMAND SUBCOMMAND' with '-h' or '--help' to view command specific usage
Refer to each sub-command's section below for details on how to invoke the command and the supported arguments.
Image Subcommands
Subcommands for qcmctl image
- Pull
- The image pull command allows the user to download an image
from a image registry while providing the necessary credentials for access.
Note:The image name assumes a latest tag if the tag isn'tspecified.
- Import
- The image import command allows the user to import an already downloaded image from a .tar file.
- List
- The image list command allows the user to display all available images in the local store.
- Status
- The image status command allows the user to display the status of an image from the local store.
- Remove
- The image remove command allows the user to remove an image from the local store.
Pod Subcommands
Subcommands for qcmctl pod
- Create
- The pod create command allows the user to create a pod sandbox environment for running containers. A pod sandbox configuration file is required; for the format, refer to Appendix: Pod Sandbox Configuration.
- List
- The pod list command allows the user to display all pods on the system.
- Status
- The pod status command allows the user to view the details of an existing pod.
- Remove
- The pod remove command allows the user to delete a pod sandbox.
Note:All containers under this pod must be removed before removing the pod.
Container Subcommands
Subcommands for qcmctl container
- Create
- The container create command allows the user to create a container in a pod sandbox. A container configuration file is required; for the format details, refer to Appendix: Container Configuration. If the pod name or identifier is provided, then the pod_sandbox_id field in the container configuration is ignored.
- List
- The container list command allows the user to display all containers on the system.
- Start
- The container start command allows the user to start a created container.
- Status
- The container status command allows the user to view the details of an existing container.
- Stop
- The container stop command allows the user to stop a running container.
- Remove
- The container remove command allows
the user to delete a container.
Note:The specified container must not be running.
- Exec
- The container exec command allows
the user to execute the specified command in a running container.
CAUTION:Ensure that an appropriate timeout is set if the command to be executed may block. If the command fails to return, then it has to be manually slayed.
NAME: qcmctl container exec - Execute a command in a running container USAGE: qcmctl container exec [options] <container-name-or-id> -- <command> [args] OPTIONS: -T, --timeout <value> - Timeout in seconds to wait for output in synchronous mode (default: 0) Setting a timeout of 0 effectively waits forever -i, --stdin - Stream STDIN in interactive mode (default: false) -t, --tty - Allocate a pseudo-TTY in interactive mode (default: false) -U, --user <uid[:gid]> - Run the command as the specified uid/gid inside the container -M, --mountpath <path> - Mount path of the qcmgr resource manager (Default: /dev/containers/qcmgr).Note:In synchronous mode, the command output is only echoed to the terminal after the command exits. The maximum amount of output that can be buffered is 8KB. Once this limit is reached, the command is terminated. - Logs
- The container logs command allows the user to output the container log file to the terminal. If the -f options is used, then qcmctl continues to output the logs until interrupted using CTRL-C.
Page updated:
