diff options
| author | Jacob McCann <jmccann.git@gmail.com> | 2015-07-01 15:08:18 +0000 |
|---|---|---|
| committer | Jacob McCann <jmccann.git@gmail.com> | 2015-07-01 15:08:18 +0000 |
| commit | c0769691bdebc1670f886454daf025620bc6fd9d (patch) | |
| tree | 5da0cf5aa2cdeadbe503b8a81cea1d9afcf796e5 /ironic_python_agent/hardware.py | |
| parent | 4c1d2cdb190a894e7cc83ed5d30061a53fe9e09b (diff) | |
| download | ironic-python-agent-c0769691bdebc1670f886454daf025620bc6fd9d.tar.gz | |
Convert Int to String for shred execute
Was running into 'expected string, int found' when calling
shred with an Int for iterations.
Change-Id: Iffce247caba5b0d62ac89b6411402c8d975cfd2f
Closes-Bug: #1469838
Diffstat (limited to 'ironic_python_agent/hardware.py')
| -rw-r--r-- | ironic_python_agent/hardware.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ironic_python_agent/hardware.py b/ironic_python_agent/hardware.py index ff1bfbeb..bdec9942 100644 --- a/ironic_python_agent/hardware.py +++ b/ironic_python_agent/hardware.py @@ -457,7 +457,7 @@ class GenericHardwareManager(HardwareManager): npasses = info.get('agent_erase_devices_iterations', 1) try: utils.execute('shred', '--force', '--zero', '--verbose', - '--iterations', npasses, block_device.name) + '--iterations', str(npasses), block_device.name) except (processutils.ProcessExecutionError, OSError) as e: msg = ("Erasing block device %(dev)s failed with error %(err)s ", {'dev': block_device.name, 'err': e}) |
