Check if image exists

This commit is contained in:
Renato Botelho 2015-10-14 08:56:17 -03:00
parent ba4527dd19
commit a4a336b2f6

View File

@ -2021,8 +2021,10 @@ snapshots_create_latest_symlink() {
if [ -f "${_image}.gz" ]; then
local _image_fixed="${_image}.gz"
else
elif [ -f "${_image}" ]; then
local _image_fixed=${_image}
else
return
fi
local _symlink=$(echo ${_image_fixed} | sed "s,${TIMESTAMP_SUFFIX},-latest,")