command_execution_options
command execution.
⚙️ Compatible targets: Linux
Parameters
Name | Documentation |
---|---|
command | Command to be executed. This parameter is required. |
args | Arguments to the command. This parameter is optional. |
run_in_audit_mode | Specify if command must be run in audit mode. Choices:
This parameter is optional. |
in_shell | Specify whether the command should be executed within a shell. Choices:
This parameter is optional. |
shell_path | Define the path to the shell to be used (applicable only in shell mode). This parameter is optional. |
chdir | Set the working directory from which the command will be executed. This parameter is optional. |
timeout | Define a timeout duration for the command execution. This parameter is optional. |
stdin | Provide input to the standard input (stdin) of the executed command. This parameter is optional. |
stdin_add_newline | Control whether a newline character is appended to the stdin input. Choices:
This parameter is optional. |
compliant_codes | Specify the compliant codes. This parameter is optional. |
repaired_codes | Specify the repaired codes. This parameter is optional. |
output_to_file | Define a file path to store the output generated by the command. This parameter is optional. |
strip_output | Controls if the EOL is strip from the output. Choices:
This parameter is optional. |
uid | Specify the user ID (UID) under which the command will be executed. This parameter is optional. |
gid | Specify the group ID (GID) under which the command will be executed. This parameter is optional. |
umask | Set the umask value for the executed command. This parameter is optional. |
env_vars | The variables to pass to the environment of the executed command. This parameter is optional. |
show_content | Controls output of the report. Choices:
This parameter is optional. |
Outcome conditions
You need to replace ${command}
with its actual canonified value.
- ✅ Ok:
command_execution_options_${command}_ok
- ☑️ Already compliant:
command_execution_options_${command}_kept
- 🟨 Repaired:
command_execution_options_${command}_repaired
- ☑️ Already compliant:
- ❌ Error:
command_execution_options_${command}_error
Example
method: command_execution_options
params:
run_in_audit_mode: 'true'
command: VALUE
output_to_file: OPTIONAL_VALUE
gid: OPTIONAL_VALUE
uid: OPTIONAL_VALUE
umask: OPTIONAL_VALUE
repaired_codes: OPTIONAL_VALUE
in_shell: 'true'
strip_output: 'true'
timeout: OPTIONAL_VALUE
stdin: OPTIONAL_VALUE
args: OPTIONAL_VALUE
env_vars: OPTIONAL_VALUE
shell_path: OPTIONAL_VALUE
stdin_add_newline: 'true'
compliant_codes: OPTIONAL_VALUE
chdir: OPTIONAL_VALUE
show_content: 'true'
Documentation
Coming soon.