Open mangelajo opened 3 weeks ago
children:
power:
type: jumpstarter.drivers.command.driver.Command
config:
on: ["./power_on.sh"]
off: ["./power_off.sh"]
What do you think about making it shell-specific instead, so we could run shell commands instead of just binaries?
Command makes it look very generic, may be Shell is more specific? WDYT?
Also some additional ideas,so we can pass arguments, and another layer so, later in time we have room for extensibility (i.e. providing other config arguments like shell interpreter or anything like that)
children:
power:
type: jumpstarter.drivers.shell.driver.Shell
config:
methods:
on: "/usr/bin/power on"
off: "/usr/bin/power off"
free: "free -h"
multiline_params: >
echo "hi,"
echo "I am a multi-line script"
echo "I accept parameters ${1} ${2}"
@NickCao, please explain in the description :)