Axonius - Deploy Files and Run Shell Command on Linux Assets
  • 16 Mar 2023
  • 1 Minute to read
  • Dark
    Light
  • PDF

Axonius - Deploy Files and Run Shell Command on Linux Assets

  • Dark
    Light
  • PDF

Article summary

Axonius - Deploy Files and Run Shell Command on Linux Assets (Deploy Files and Run Linux Shell Command) action allows you to populate a field with the output of running the command supplied in the Command field via SSH, on each of the query results entities, which are Linux devices.

See Creating Enforcement Sets to learn more about adding Enforcement Actions to Enforcement Sets.

Note:

General Settings

  • Action name - The name of this Enforcement Action. The system sets a default name. You can change the name.
  • Configure Dynamic Values - Toggle on to enter a Dynamic Value statement. See Creating Enforcement Action Dynamic Value Statements to learn more about Dynamic Value statement syntax.

To configure the Deploy Files and Run Linux Shell Command action, do as follows:

  1. From the Action Library, click Deploy Files and Run Commands, and then click Deploy Files and Run Linux Shell Command.

  2. Define a unique action name.

  3. Specify the information required to run the Linux Shell Command. Most of the action configuration and logic are the same as the ones used when Connecting Linux SSH Adapter.

  4. Specify the command you want to run on the Linux device. Add a condition to the command (for example, '&& echo Success || echo Fail') to print the result into the Command Name field. This field can then be used in future queries.

  5. To deploy a single or multiple files on the Linux device:

    1. Choose a file to be uploaded. You can upload one or multiple files. Existing files will be overridden.
    2. Specify the path on the Linux device the files will be uploaded. If not populated, the files are uploaded to "/tmp" folder.
    3. To delete the files afer executing the specified command line, select the Delete Files After Execution checkbox.
    4. Specify the permissions given to the uploded files. This Defaults to "777".
  6. If you are using multi-nodes, choose the Axonius node to use to interact with the adapter when executing the enforcement action.

  7. Save the action.


For more details about other Enforcement Actions available, see Action Library.


Was this article helpful?