summaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/cinder-volume/files/losetup.sh
blob: 1f0b2b0e6eb5ff34e09486d8c3523becab958b00 (plain)
1
2
3
4
5
6
7
loop_dev=`losetup -a |grep "/var/cinder.img"|awk -F':' '{print $1}'`
if [ -z $loop_dev ]; then
  losetup -f --show /var/cinder.img
else
  echo $loop_dev
fi