Skip to main content
Upload, list, and remove custom binaries on Lager Boxes for use in Python scripts.

Syntax

Commands


Command Reference

add

Upload a binary file to the Lager Box.
Arguments:
  • BINARY_PATH - Local path to the binary file
Options:
  • --box BOX - Lager Box name or IP address
  • --name NAME - Name for the binary on Lager Box (defaults to filename)
  • --yes - Skip confirmation prompt
Examples:

list

List all custom binaries on a Lager Box.
Output:
If the box has no binaries, the list reads (no binaries installed). If the directory is not mounted in the container yet, the output ends with Note: Directory is not yet mounted in container. and Run: lager update --box my-lager-box.

remove

Remove a binary from the Lager Box.
Arguments:
  • BINARY_NAME - Name of the binary to remove
Options:
  • --box BOX - Lager Box name or IP address
  • --yes - Skip confirmation prompt
Examples:

Storage Locations

Binaries are stored in:

Using Binaries in Python Scripts

Once uploaded, binaries can be called from Python scripts running on the Lager Box:

Adding to PATH (Optional)

To call binaries without the full path, modify the Lager Box Dockerfile:
Then rebuild the container:
Now you can call binaries directly:

Examples


Use Cases

Device Communication Tools

Upload vendor-specific tools for device interaction:

Firmware Tools

Upload custom firmware manipulation tools:

Test Utilities

Upload test-specific utilities:

Notes

  • Binaries must be Linux x86_64 compatible
  • Files are automatically made executable
  • A new binary is visible in the container at once, through a volume mount. On a box where that mount is not active yet, add prints Note: A first-time setup needs a container restart. Run lager update on that box once
  • File sizes are displayed in human-readable format
  • Use --yes to skip confirmation in scripts