diskimage-builder/diskimage_builder/block_device
Ian Wienand 0d8c4270c0 exec_sudo: check cmd for str, log output and raise exception
To avoid any confusion, commands passed to exec_sudo() should be a
list of "str"s.  Log a message if we see unicode issues.

This also adds a debug trace of all output.  stderr is captured.

This is modified to raise CalledProcessError on failure, like
check_call().  Calls that are ok to fail will need to explicitly catch
and ignore this.

The two calls that we expect to fail are wrapped

We wish to try rolling back if one of these command raises an
exception.  Modify the create handler to initiate rollback on all
exceptions.

Change-Id: Iee4fa41ffaf243e4728bf3a5eeec5c8fa8d2dadc
2017-05-11 09:45:25 +10:00
..
level0 Add refactor of tree-like vs graph 2017-05-03 05:27:43 +00:00
level1 exec_sudo: check cmd for str, log output and raise exception 2017-05-11 09:45:25 +10:00
tests Refactor: block-device handling (local loop) 2016-09-08 04:31:01 +00:00
__init__.py Refactor block_device: passing command line parameters 2017-04-23 09:51:18 +00:00
blockdevice.py exec_sudo: check cmd for str, log output and raise exception 2017-05-11 09:45:25 +10:00
blockdevicesetupexception.py Refactor: block-device handling (partitioning) 2017-01-24 19:59:10 +00:00
plugin_base.py Use stevedore for plugin config of block device 2017-03-24 21:42:47 +00:00
tree_config.py Add refactor of tree-like vs graph 2017-05-03 05:27:43 +00:00
utils.py exec_sudo: check cmd for str, log output and raise exception 2017-05-11 09:45:25 +10:00