Docker-VM-Runner can expose a Redfish-compatible BMC interface via sushy-emulator, allowing remote power and boot management of the guest VM. This guide covers enabling the service and performing common operations.
- Map the HTTPS port and set
REDFISH_ENABLE=1:docker run --rm -it \ --name vm1 \ --device /dev/kvm:/dev/kvm \ -p 2222:2222 \ -p 8443:8443 \ -e REDFISH_ENABLE=1 \ ghcr.io/munenick/docker-vm-runner:latest
- Optional: persist certificates by mounting a volume at
/data:-v myvm:/data
- Optional: override credentials using
REDFISH_USERNAME/REDFISH_PASSWORD.
Set REDFISH_ENABLE=0 (default) or omit the variable entirely. The service and TLS bootstrap are skipped, reducing startup overhead.
- Base URL:
https://<host>:${REDFISH_PORT:-8443} - Default credentials:
admin/password - Trust: self-signed certificate stored under
/var/lib/docker-vm-runner/certs(persist it if needed).
Example: list systems
curl -k -u admin:password https://localhost:8443/redfish/v1/Systems# Graceful shutdown
curl -k -u admin:password \
-H "Content-Type: application/json" \
-d '{"ResetType":"GracefulShutdown"}' \
https://localhost:8443/redfish/v1/Systems/vm1/Actions/ComputerSystem.Reset
# Force off
curl -k -u admin:password \
-H "Content-Type: application/json" \
-d '{"ResetType":"ForceOff"}' \
https://localhost:8443/redfish/v1/Systems/vm1/Actions/ComputerSystem.Reset
# Power on
curl -k -u admin:password \
-H "Content-Type: application/json" \
-d '{"ResetType":"On"}' \
https://localhost:8443/redfish/v1/Systems/vm1/Actions/ComputerSystem.Reset
# Reboot
curl -k -u admin:password \
-H "Content-Type: application/json" \
-d '{"ResetType":"GracefulRestart"}' \
https://localhost:8443/redfish/v1/Systems/vm1/Actions/ComputerSystem.ResetUse ForceRestart or ForceOff when the guest does not react to graceful commands.
curl -k -u admin:password \
https://localhost:8443/redfish/v1/Systems/vm1 | jq '.PowerState'Change the next boot device (e.g., to network):
curl -k -u admin:password \
-H "Content-Type: application/json" \
-d '{"Boot":{"BootSourceOverrideEnabled":"Once","BootSourceOverrideTarget":"Pxe"}}' \
https://localhost:8443/redfish/v1/Systems/vm1Valid targets include Pxe, Hdd, Cd, etc. Ensure the VM definition matches the requested devices.
- Combine Redfish automation with SSH or noVNC sessions for installation workflows.
- To run multiple VMs, ensure each container uses a unique
REDFISH_PORTandSystemId(REDFISH_SYSTEM_ID). - Logs appear in
docker logs vm1; Redfish requests are also visible inside the container under/var/log.