Fix block_devices to not rely on device path #131
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The
block_devices
role currently uses the device path (e.g. /dev/sdb) to identify the device to create fileystems on and the fileystem (e.g. /dev/sdb1) to mount. This is unsafe as device letters can/do change after reboot.This PR changes the role to:
Note that for openstack volumes the serial number is set to the volume ID hence can be retrieved from e.g. terraform.