POSTIN
/bin/sh
# create it if it doesn't already exist as a link
# If it is an existing file other than a link, do nothing
[ -L /etc/imagefactory/plugins.d/Rackspace.info ] ||
[ -e /etc/imagefactory/plugins.d/Rackspace.info ] ||
ln -s /usr/lib/python2.7/site-packages/imagefactory_plugins/Rackspace/Rackspace.info /etc/imagefactory/plugins.d/Rackspace.info
exit 0
POSTUN
/bin/sh
if [ "$1" = "0" ]; then
# clean up the link if it exists - if it doesn't or if this is a regular file, do nothing
[ -L /etc/imagefactory/plugins.d/Rackspace.info ] && rm -f /etc/imagefactory/plugins.d/Rackspace.info
fi
exit 0