Merge lp:~smoser/cloud-init/trunk.doc-seedrandom into lp:~cloud-init-dev/cloud-init/trunk

Proposed by Scott Moser
Status: Merged
Merged at revision: 1178
Proposed branch: lp:~smoser/cloud-init/trunk.doc-seedrandom
Merge into: lp:~cloud-init-dev/cloud-init/trunk
Diff against target: 52 lines (+48/-0)
1 file modified
doc/examples/cloud-config-random-seed.txt (+48/-0)
To merge this branch: bzr merge lp:~smoser/cloud-init/trunk.doc-seedrandom
Reviewer Review Type Date Requested Status
cloud-init Commiters Pending
Review via email: mp+275062@code.launchpad.net

Description of the change

Doc: document random_seed in cloud-config

As raised in bug 1424549 this needs some documentation.

To post a comment you must log in.
1152. By Scott Moser

add random_seed dict

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'doc/examples/cloud-config-random-seed.txt'
2--- doc/examples/cloud-config-random-seed.txt 1970-01-01 00:00:00 +0000
3+++ doc/examples/cloud-config-random-seed.txt 2015-10-20 16:18:46 +0000
4@@ -0,0 +1,48 @@
5+#cloud-config
6+
7+# cloud-config can configure a random seed through the 'random_seed' module.
8+# The purpose of the module is effectively to write random data into
9+# /dev/urandom to seed this system's entropy pool to improve the random data
10+# generated. This is especially important early in boot and first boot when
11+# random data is required by ssh to generate host keys.
12+
13+# The configuration looks like this:
14+#
15+# random_seed:
16+# file: "/dev/urandom"
17+# the file to write data to. defaults to '/dev/urandom'
18+# this is presented to 'command' below in an environment variable
19+# named RANDOM_SEED_FILE.
20+#
21+# data: ""
22+# if data is provided, it will be written to 'file'.
23+# This gives the user a way to provide their own random data.
24+#
25+# command: ['pollinate', '-q']
26+# This command is run, and is expected to aid in seeding entropy
27+# pool. The default command is as shown. It can be set to anything.
28+# The command will have access to the environment variable
29+# RANDOM_SEED_FILE that is set to 'file' from above.
30+#
31+# To set a specific pollinate server, you could use:
32+# command: ['pollinate', '--server', 'http://your.server/']
33+#
34+# If the command exits failure, a warning will be raised.
35+#
36+# command_required: False
37+# command_required indicates if this config module should fail
38+# if the command is not present. For example, if your image does
39+# not have 'pollinate' and you set 'command_required' to True
40+# then this module would raise an error.
41+#
42+random_seed:
43+ file: /dev/urandom
44+ data: ""
45+ command: ['pollinate', '-q']
46+ command_required: False
47+
48+#
49+# Additionally, if the datasource provides some random data, cloud-init
50+# will use that as well. The Openstack datasource provides a hunk of random
51+# data in its metadata, and the Azure datasource provides random data
52+# in an acpi table (/sys/firmware/acpi/tables/OEM0).