Support having version-specific lxc-config as conf/${DISTRIBUTION}-${RELEASE}

if present, this is used, otherwise conf/${DISTRIBUTION} as before.
This commit is contained in:
Michael Adam 2015-01-07 10:52:08 +01:00
parent e84c681e38
commit 022112d019

View file

@ -23,7 +23,11 @@ popd &>>${LOG}
# Prepare package contents # Prepare package contents
log 'Preparing box package contents' log 'Preparing box package contents'
if [ -f conf/${DISTRIBUTION}-${RELEASE} ]; then
cp conf/${DISTRIBUTION}-${RELEASE} ${WORKING_DIR}/lxc-config
else
cp conf/${DISTRIBUTION} ${WORKING_DIR}/lxc-config cp conf/${DISTRIBUTION} ${WORKING_DIR}/lxc-config
fi
cp conf/metadata.json ${WORKING_DIR} cp conf/metadata.json ${WORKING_DIR}
sed -i "s/<TODAY>/${NOW}/" ${WORKING_DIR}/metadata.json sed -i "s/<TODAY>/${NOW}/" ${WORKING_DIR}/metadata.json