summaryrefslogtreecommitdiff
path: root/doc/examples/cloud-config-run-cmds.txt
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@yahoo-inc.com>2013-01-24 18:41:26 -0800
committerJoshua Harlow <harlowja@yahoo-inc.com>2013-01-24 18:41:26 -0800
commit6fb6fe24d5ba185d42f2d7a82c3c54d26fea3392 (patch)
tree44154d0e09b265078bda33e85f171de55b11b48e /doc/examples/cloud-config-run-cmds.txt
parent6f0756e5501ae660b2173ff558867941ab963a42 (diff)
downloadvyos-cloud-init-6fb6fe24d5ba185d42f2d7a82c3c54d26fea3392.tar.gz
vyos-cloud-init-6fb6fe24d5ba185d42f2d7a82c3c54d26fea3392.zip
Add docs which can be used on readthedocs.org
Include a new set of docs that can be used to create a readthedocs.org site, which includes examples, directory layout, capabilities and such. This in-code documentation then allows for readthedocs.org to create a website directly from the cloud-init codebase.
Diffstat (limited to 'doc/examples/cloud-config-run-cmds.txt')
-rw-r--r--doc/examples/cloud-config-run-cmds.txt21
1 files changed, 21 insertions, 0 deletions
diff --git a/doc/examples/cloud-config-run-cmds.txt b/doc/examples/cloud-config-run-cmds.txt
new file mode 100644
index 00000000..61b3bd63
--- /dev/null
+++ b/doc/examples/cloud-config-run-cmds.txt
@@ -0,0 +1,21 @@
+#cloud-config
+
+# run commands
+# default: none
+# runcmd contains a list of either lists or a string
+# each item will be executed in order at rc.local like level with
+# output to the console
+# - if the item is a list, the items will be properly executed as if
+# passed to execve(3) (with the first arg as the command).
+# - if the item is a string, it will be simply written to the file and
+# will be interpreted by 'sh'
+#
+# Note, that the list has to be proper yaml, so you have to escape
+# any characters yaml would eat (':' can be problematic)
+runcmd:
+ - [ ls, -l, / ]
+ - [ sh, -xc, "echo $(date) ': hello world!'" ]
+ - [ sh, -c, echo "=========hello world'=========" ]
+ - ls -l /root
+ - [ wget, "http://slashdot.org", -O, /tmp/index.html ]
+