CLI client-side mechanism, enforcing IP exclusivity in asset data
from Snipe-IT, covering system IP, RTE IP, Sonoff IP & PiKVM IP.
Throws DuplicatedIpException to prevent user from remote hardware
manipulation if duplicated IP entries exist.
Signed-off-by: Mateusz Maciejewski <mateusz.maciejewski@3mdeb.com>
Without this option there is no way to setup DUT with RTE in home lab.
This commit should be first step for OSFV to allow community setup their
own DUTs and validate those.
Signed-off-by: Piotr Król <piotr.krol@3mdeb.com>
Sonoff returns capital ON/OFF, while relay returned on/off.
We define relay strings here, so can be changed here to
unify the reponses, no matter which power control method
was used at the time.
The more proper solution would be to implement:
https://github.com/Dasharo/osfv-scripts/issues/77
Signed-off-by: Maciej Pijanowski <maciej.pijanowski@3mdeb.com>
Somehow fixes: https://github.com/Dasharo/osfv-scripts/issues/69
I think in the end we do not need that much logic in this CLI tool, but
the PSU control was definitely missing. We provide a single interface
to control the PSU, no matter what power control (relay, Sonoff) is in
place.
It has been added and exposed to the OSFV via RF libs. The CLI tool
should not know much about the firmware behavior, such as whether
the DUT will power on when PSU is enabled, or not. This is often
configurable, even at runtime, and should be handled in test environment
instead. In many cases, the CLI tool may even operate with no firmware
at all, or with bricked DUT.
Signed-off-by: Maciej Pijanowski <maciej.pijanowski@3mdeb.com>
Use ACPI nomenclature to be consistent and rename OFF to S5. Both OFF
and G3 mean powered off state, however ACPI differentiates soft off
with PSU/AC active (S5) and hard off with PSU/AC inactive (G3).
Also the logic controlling the power state during flashing was
inverted. We always put the device to S5 state (PSU/AC active) before
attempting to flash. But for G3 path, the PSU/AC stayed on, while
should be turned off. All board configs have been changed to their
proper states to reflect the correct power logic.
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>