3.2.4. prlctl exec, enter

Allow running arbitrary commands in a container.

Syntax. 

prlctl exec <CT_name> [--without-shell] <command>
prlctl enter <CT_name>

where <command> is a string to be executed in the container. If <command> is specified as -, then the commands for execution will be read from the standard input until the end of file or exit is encountered.

Table 3.10. Options

NameDescription

<CT_name>

Container name.

--without-shell

Run commands directly without bash or cmd shell.

When using prlctl exec, remember that the shell parses the command-line and, if your command has shell metacharacters in it, you should escape or quote them.

The prlctl enter command is similar to prlctl exec /bin/bash. The difference between the two is that prlctl enter makes the shell interpreter believe that it is connected to a terminal. As such, you receive a shell prompt and are able to execute multiple commands as if you were logged in to the container.