summaryrefslogtreecommitdiff
path: root/doc/examples
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2012-11-13 14:18:26 -0500
committerScott Moser <smoser@ubuntu.com>2012-11-13 14:18:26 -0500
commitf6e994611cf87ea40f2c90991126d29e54b0efed (patch)
tree0cfb872a7280c2020239c83aef06fbe8ad9a7329 /doc/examples
parentb503a6827a8aca13246e98272d83cf11fdeab820 (diff)
parentdf38cb7a9f99fbb5fdaddeb08e43d74af30372c8 (diff)
downloadvyos-cloud-init-f6e994611cf87ea40f2c90991126d29e54b0efed.tar.gz
vyos-cloud-init-f6e994611cf87ea40f2c90991126d29e54b0efed.zip
support 'power_state' cloud-config for specifying shutdown
this adds 'power-state-change' config module that allows the user to specify in cloud-config syntax that a system reboot or shutdown should occur after cloud-init is done.
Diffstat (limited to 'doc/examples')
-rw-r--r--doc/examples/cloud-config.txt21
1 files changed, 21 insertions, 0 deletions
diff --git a/doc/examples/cloud-config.txt b/doc/examples/cloud-config.txt
index 12bf2c91..09298655 100644
--- a/doc/examples/cloud-config.txt
+++ b/doc/examples/cloud-config.txt
@@ -578,3 +578,24 @@ manual_cache_clean: False
# A list of key types (first token of a /etc/ssh/ssh_key_*.pub file)
# that should be skipped when outputting key fingerprints and keys
# to the console respectively.
+
+## poweroff or reboot system after finished
+# default: none
+#
+# power_state can be used to make the system shutdown, reboot or
+# halt after boot is finished. This same thing can be acheived by
+# user-data scripts or by runcmd by simply invoking 'shutdown'.
+#
+# Doing it this way ensures that cloud-init is entirely finished with
+# modules that would be executed, and avoids any error/log messages
+# that may go to the console as a result of system services like
+# syslog being taken down while cloud-init is running.
+#
+# delay: form accepted by shutdown. default is 'now'. other format
+# accepted is +m (m in minutes)
+# mode: required. must be one of 'poweroff', 'halt', 'reboot'
+# message: provided as the message argument to 'shutdown'. default is none.
+power_state:
+ delay: 30
+ mode: poweroff
+ message: Bye Bye