Merge "Validate the target directory exists before linking."
This commit is contained in:
commit
0d61aaff47
@ -430,6 +430,10 @@ function link_release {
|
|||||||
if [[ -d "/opt/openstack-ansible" ]]; then
|
if [[ -d "/opt/openstack-ansible" ]]; then
|
||||||
mv "/opt/openstack-ansible" "/opt/openstack-ansible.bak"
|
mv "/opt/openstack-ansible" "/opt/openstack-ansible.bak"
|
||||||
fi
|
fi
|
||||||
|
if [[ ! -d "$1" ]]; then
|
||||||
|
failure "Make sure the target "$1" exists. "
|
||||||
|
exit 99
|
||||||
|
fi
|
||||||
ln -sf "$1" "/opt/openstack-ansible"
|
ln -sf "$1" "/opt/openstack-ansible"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user