systemd: ensure /storage/.cache exists before writing machine-id

This commit is contained in:
chewitt 2016-06-06 11:53:29 +04:00
parent 1aa0fdd9e6
commit 60d7aebfdc

View File

@ -36,6 +36,7 @@ fi
if [ -z "$MACHINEID" ]; then if [ -z "$MACHINEID" ]; then
MACHINEID=`echo $MAC_ADDRESS | md5sum | cut -f1 -d" "` MACHINEID=`echo $MAC_ADDRESS | md5sum | cut -f1 -d" "`
mkdir -p /storage/.cache
fi fi
echo "$MACHINEID" > /storage/.cache/machine-id echo "$MACHINEID" > /storage/.cache/machine-id