action #33388

Updated by okurz almost 6 years ago

## Motivation 
 The current implementation of the spvm backend makes use of functions ( e.g. `use_ssh_serial_console` located in `lib/`) from other "backends". 
 This is good enough for a first proof of concept but for the sake of clarity and further maintainability this should reside resist in a separate file which is shared/included from the backends using it. 

 ## Acceptance criteria 
 * **AC1:** Have clearly seperated backends with shared common functions 
 * **AC2:** Do not functions. Don't include any (more generic) functions from other backends (e.g. from ipmi into spvm) 

 ## Suggestions 
 * Extract method "use_ssh_serial_console" into a common lib, e.g. "ssh_remote_console_backend_something_foobar" 
 * Find occurences like in where we look for "s390x || ipmi || spvm" and replace this with an explicit function returning a boolean value for what it really is, e.g. "no_local_tty" or "remote_backend" or "relies_on_ssh_terminal" 
 * Create followup sibling ticket for all necessary work for other backends 

 ## Further details 
 Focus on spvm, leave the rest for the parent epic backends.