From b1d9c92f5bc6f711e104ceb981ded658249c3255 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Thu, 10 Mar 2016 10:41:48 -0500 Subject: generator: use /run/cloud-init instead of /run --- systemd/cloud-init-generator | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'systemd') diff --git a/systemd/cloud-init-generator b/systemd/cloud-init-generator index b7a2f17a..8156db58 100755 --- a/systemd/cloud-init-generator +++ b/systemd/cloud-init-generator @@ -3,7 +3,7 @@ set -f LOG="" DEBUG_LEVEL=1 -LOG_D="/run" +LOG_D="/run/cloud-init" ENABLE="enabled" DISABLE="disabled" CLOUD_SYSTEM_TARGET="/lib/systemd/system/cloud-init.target" @@ -17,7 +17,8 @@ debug() { [ "$lvl" -gt "$DEBUG_LEVEL" ] && return if [ -z "$LOG" ]; then local log="$LOG_D/${0##*/}.log" - { : > "$log"; } >/dev/null 2>&1 && LOG="$log" || + { [ -d "$LOG_D" ] || mkdir -p "$LOG_D"; } && + { : > "$log"; } >/dev/null 2>&1 && LOG="$log" || LOG="/dev/kmsg" fi echo "$@" >> "$LOG" -- cgit v1.2.3