1
0
mirror of https://github.com/rancher/os.git synced 2025-06-29 16:26:50 +00:00
os/cmd/power
Chris Marchesi 7d86fa5f8b
cmd/power: Another shutdown command fix
It looks like some arguments for shutdown/halt/poweroff have been moved
to a conditional block that works off of how the command was actually
called. However, this value is derived from argv 0, without any sort of
normalization to make sure it matches the relative commands used to
determine how arguments are handled.

This has particular implications when power management commands are
called via absolute commands, as for example in the case of
open-vm-tools which calls /sbin/shutdown -h now specifically when
shutting down a system.

This corrects the situation by passing argv 0 through filepath.Base
before operating on it.
2018-03-06 14:16:44 -08:00
..
power.go Fixes the following scenario can not reboot (#2236) 2018-01-25 16:25:09 +08:00
shutdown.go cmd/power: Another shutdown command fix 2018-03-06 14:16:44 -08:00