Post

PVE LXC Execute Command

This script allows administrators to execute a custom command inside one or multiple LXC containers on a Proxmox VE node. Containers can be selectively excluded via an interactive checklist. If a container is stopped, the script will automatically start it, run the command, and then shut it down again. Only Debian and Ubuntu based containers are supported.

PVE LXC Execute Command

Installation

Default install:

1
bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/tools/pve/execute.sh)"

Notes

Execute within the Proxmox shell.
Non-Debian/Ubuntu containers will be skipped automatically.
Stopped containers will be started temporarily to run the command, then shut down again.

This post is licensed under CC BY 4.0 by the author.