From 10d4048677a90ab66ab4a314f311163b6e6d9cf1 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Tue, 25 Jan 2011 02:26:22 +0000 Subject: add support for redirecting output of cloud-init, cloud-config and cloud-final --- doc/examples/cloud-config.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'doc/examples') diff --git a/doc/examples/cloud-config.txt b/doc/examples/cloud-config.txt index e6d33465..a55670f6 100644 --- a/doc/examples/cloud-config.txt +++ b/doc/examples/cloud-config.txt @@ -292,3 +292,21 @@ resize_rootfs: True # this message is written by cloud-final when the system is finished # its first boot final_message: "The system is finally up, after $UPTIME seconds" + +# configure where output will go +# 'output' entry is a dict with 'init', 'config', 'final' or 'all' +# entries. Each one defines where +# cloud-init, cloud-config, cloud-config-final or all output will go +# each entry in the dict can be a string, list or dict. +# if it is a string, it refers to stdout +# if it is a list, entry 0 is stdout, entry 1 is stderr +# if it is a dict, it is expected to have 'output' and 'error' fields +# default is to write to console only +# the special entry "&1" for an error means "same location as stdout" +# (Note, that '&1' has meaning in yaml, so it must be quoted) +output: + init: "> /var/log/my-cloud-init.log" + config: [ ">> /tmp/foo.out", "> /tmp/foo.err" ] + final: + output: "| tee /tmp/final.stdout | tee /tmp/bar.stdout" + error: "&1" -- cgit v1.2.3