Before:
*********************************************************
R to reboot P to poweroff S to enter shell
K to launch SSH server L to enable sending DTS logs V to enable verbose mode
Enter an option:
Now:
*********************************************************
R to reboot P to poweroff S to enter shell
K to launch SSH server L to enable sending DTS logs
V to enable verbose mode
Enter an option:
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
The installation workflows must be as linear as possbile for better
readability and scalability.
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
Before deploing we do some configuration based on the list of the
firmware versions the target supports and on DPP subscription user
has.
Previously this configuration lived beside the code responsible for
deploying, as a result, the deploying workflows was messy, had nesting
levels over 3, and nonlinear and complex logic.
This commit tries to separate this configuration and deploying to make
it more readable and scallable.
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
This function is useful not unly during update workflow, but every time
firmware is being deployed
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
"test -v" checks whether a variable has been declared, it does not check
its value. We sometimes use "unset" for some variables, and then check
again with "test -v". The problem is, "unset" erases variable value, but
the variable still exists, so the "test -v" will be true before, as well
as after the "unset".
We must use "test -n" (whether a variable holds non-zero length
string value) and "test -z" (whether a variable holds zero length string
value) to check string values of variables. This way the "unset" will
work.
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
Variables with links to hashes of the firmware binaries are always set,
use variables with links to firmware binaries instead.
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
Configurations of all supported platforms are done inside
board_config function as switch/case Bash statements. The list of
supported platforms has grown a lot since then, and the function became
unreadable, so adding and managing configurations became difficult and
error-prone.
This commit adds some default configuration values as well as tries to
reuse some configuration code.
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>