Merge ~powersj/cloud-init:docs/whitespace_spelling into cloud-init:master

Proposed by Joshua Powers
Status: Merged
Approved by: Dan Watkins
Approved revision: b16a3abc6524904dd74613180b6d5e88e2332e68
Merge reported by: Server Team CI bot
Merged at revision: not available
Proposed branch: ~powersj/cloud-init:docs/whitespace_spelling
Merge into: cloud-init:master
Diff against target: 857 lines (+175/-131)
17 files modified
doc/rtd/topics/datasources/altcloud.rst (+12/-11)
doc/rtd/topics/datasources/azure.rst (+2/-1)
doc/rtd/topics/datasources/cloudstack.rst (+1/-1)
doc/rtd/topics/datasources/configdrive.rst (+8/-8)
doc/rtd/topics/datasources/digitalocean.rst (+4/-2)
doc/rtd/topics/datasources/ec2.rst (+6/-5)
doc/rtd/topics/datasources/exoscale.rst (+6/-6)
doc/rtd/topics/datasources/nocloud.rst (+8/-8)
doc/rtd/topics/datasources/opennebula.rst (+15/-15)
doc/rtd/topics/datasources/openstack.rst (+2/-1)
doc/rtd/topics/datasources/smartos.rst (+7/-5)
doc/rtd/topics/debugging.rst (+7/-7)
doc/rtd/topics/dir_layout.rst (+22/-17)
doc/rtd/topics/examples.rst (+1/-1)
doc/rtd/topics/format.rst (+53/-28)
doc/rtd/topics/merging.rst (+12/-6)
doc/rtd/topics/network-config-format-v2.rst (+9/-9)
Reviewer Review Type Date Requested Status
Dan Watkins Approve
Server Team CI bot continuous-integration Approve
Review via email: mp+372104@code.launchpad.net

Commit message

docs: fix whitespace, spelling, and line length

To post a comment you must log in.
Revision history for this message
Server Team CI bot (server-team-bot) wrote :

PASSED: Continuous integration, rev:b16a3abc6524904dd74613180b6d5e88e2332e68
https://jenkins.ubuntu.com/server/job/cloud-init-ci/1100/
Executed test runs:
    SUCCESS: Checkout
    SUCCESS: Unit & Style Tests
    SUCCESS: Ubuntu LTS: Build
    SUCCESS: Ubuntu LTS: Integration
    IN_PROGRESS: Declarative: Post Actions

Click here to trigger a rebuild:
https://jenkins.ubuntu.com/server/job/cloud-init-ci/1100//rebuild

review: Approve (continuous-integration)
Revision history for this message
Dan Watkins (oddbloke) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/doc/rtd/topics/datasources/altcloud.rst b/doc/rtd/topics/datasources/altcloud.rst
index eeb197f..9d7e3de 100644
--- a/doc/rtd/topics/datasources/altcloud.rst
+++ b/doc/rtd/topics/datasources/altcloud.rst
@@ -3,24 +3,25 @@
3Alt Cloud3Alt Cloud
4=========4=========
55
6The datasource altcloud will be used to pick up user data on `RHEVm`_ and `vSphere`_.6The datasource altcloud will be used to pick up user data on `RHEVm`_ and
7`vSphere`_.
78
8RHEVm9RHEVm
9-----10-----
1011
11For `RHEVm`_ v3.0 the userdata is injected into the VM using floppy12For `RHEVm`_ v3.0 the userdata is injected into the VM using floppy
12injection via the `RHEVm`_ dashboard "Custom Properties". 13injection via the `RHEVm`_ dashboard "Custom Properties".
1314
14The format of the Custom Properties entry must be:15The format of the Custom Properties entry must be:
1516
16::17::
17 18
18 floppyinject=user-data.txt:<base64 encoded data>19 floppyinject=user-data.txt:<base64 encoded data>
1920
20For example to pass a simple bash script:21For example to pass a simple bash script:
2122
22.. sourcecode:: sh23.. sourcecode:: sh
23 24
24 % cat simple_script.bash25 % cat simple_script.bash
25 #!/bin/bash26 #!/bin/bash
26 echo "Hello Joe!" >> /tmp/JJV_Joe_out.txt27 echo "Hello Joe!" >> /tmp/JJV_Joe_out.txt
@@ -38,7 +39,7 @@ set the "Custom Properties" when creating the RHEMv v3.0 VM to:
38**NOTE:** The prefix with file name must be: ``floppyinject=user-data.txt:``39**NOTE:** The prefix with file name must be: ``floppyinject=user-data.txt:``
3940
40It is also possible to launch a `RHEVm`_ v3.0 VM and pass optional user41It is also possible to launch a `RHEVm`_ v3.0 VM and pass optional user
41data to it using the Delta Cloud. 42data to it using the Delta Cloud.
4243
43For more information on Delta Cloud see: http://deltacloud.apache.org44For more information on Delta Cloud see: http://deltacloud.apache.org
4445
@@ -46,12 +47,12 @@ vSphere
46-------47-------
4748
48For VMWare's `vSphere`_ the userdata is injected into the VM as an ISO49For VMWare's `vSphere`_ the userdata is injected into the VM as an ISO
49via the cdrom. This can be done using the `vSphere`_ dashboard 50via the cdrom. This can be done using the `vSphere`_ dashboard
50by connecting an ISO image to the CD/DVD drive.51by connecting an ISO image to the CD/DVD drive.
5152
52To pass this example script to cloud-init running in a `vSphere`_ VM53To pass this example script to cloud-init running in a `vSphere`_ VM
53set the CD/DVD drive when creating the vSphere VM to point to an54set the CD/DVD drive when creating the vSphere VM to point to an
54ISO on the data store. 55ISO on the data store.
5556
56**Note:** The ISO must contain the user data.57**Note:** The ISO must contain the user data.
5758
@@ -61,13 +62,13 @@ Create the ISO
61^^^^^^^^^^^^^^62^^^^^^^^^^^^^^
6263
63.. sourcecode:: sh64.. sourcecode:: sh
64 65
65 % mkdir my-iso66 % mkdir my-iso
6667
67NOTE: The file name on the ISO must be: ``user-data.txt``68NOTE: The file name on the ISO must be: ``user-data.txt``
6869
69.. sourcecode:: sh70.. sourcecode:: sh
70 71
71 % cp simple_script.bash my-iso/user-data.txt72 % cp simple_script.bash my-iso/user-data.txt
72 % genisoimage -o user-data.iso -r my-iso73 % genisoimage -o user-data.iso -r my-iso
7374
@@ -75,7 +76,7 @@ Verify the ISO
75^^^^^^^^^^^^^^76^^^^^^^^^^^^^^
7677
77.. sourcecode:: sh78.. sourcecode:: sh
78 79
79 % sudo mkdir /media/vsphere_iso80 % sudo mkdir /media/vsphere_iso
80 % sudo mount -o loop user-data.iso /media/vsphere_iso81 % sudo mount -o loop user-data.iso /media/vsphere_iso
81 % cat /media/vsphere_iso/user-data.txt82 % cat /media/vsphere_iso/user-data.txt
@@ -84,7 +85,7 @@ Verify the ISO
84Then, launch the `vSphere`_ VM the ISO user-data.iso attached as a CDROM.85Then, launch the `vSphere`_ VM the ISO user-data.iso attached as a CDROM.
8586
86It is also possible to launch a `vSphere`_ VM and pass optional user87It is also possible to launch a `vSphere`_ VM and pass optional user
87data to it using the Delta Cloud. 88data to it using the Delta Cloud.
8889
89For more information on Delta Cloud see: http://deltacloud.apache.org90For more information on Delta Cloud see: http://deltacloud.apache.org
9091
diff --git a/doc/rtd/topics/datasources/azure.rst b/doc/rtd/topics/datasources/azure.rst
index b41cddd..8328dfa 100644
--- a/doc/rtd/topics/datasources/azure.rst
+++ b/doc/rtd/topics/datasources/azure.rst
@@ -82,7 +82,8 @@ The settings that may be configured are:
82 provided command to obtain metadata.82 provided command to obtain metadata.
83 * **apply_network_config**: Boolean set to True to use network configuration83 * **apply_network_config**: Boolean set to True to use network configuration
84 described by Azure's IMDS endpoint instead of fallback network config of84 described by Azure's IMDS endpoint instead of fallback network config of
85 dhcp on eth0. Default is True. For Ubuntu 16.04 or earlier, default is False.85 dhcp on eth0. Default is True. For Ubuntu 16.04 or earlier, default is
86 False.
86 * **data_dir**: Path used to read metadata files and write crawled data.87 * **data_dir**: Path used to read metadata files and write crawled data.
87 * **dhclient_lease_file**: The fallback lease file to source when looking for88 * **dhclient_lease_file**: The fallback lease file to source when looking for
88 custom DHCP option 245 from Azure fabric.89 custom DHCP option 245 from Azure fabric.
diff --git a/doc/rtd/topics/datasources/cloudstack.rst b/doc/rtd/topics/datasources/cloudstack.rst
index a3101ed..95b9587 100644
--- a/doc/rtd/topics/datasources/cloudstack.rst
+++ b/doc/rtd/topics/datasources/cloudstack.rst
@@ -7,7 +7,7 @@ CloudStack
7sshkey thru the Virtual-Router. The datasource obtains the VR address via7sshkey thru the Virtual-Router. The datasource obtains the VR address via
8dhcp lease information given to the instance.8dhcp lease information given to the instance.
9For more details on meta-data and user-data,9For more details on meta-data and user-data,
10refer the `CloudStack Administrator Guide`_. 10refer the `CloudStack Administrator Guide`_.
1111
12URLs to access user-data and meta-data from the Virtual Machine. Here 10.1.1.112URLs to access user-data and meta-data from the Virtual Machine. Here 10.1.1.1
13is the Virtual Router IP:13is the Virtual Router IP:
diff --git a/doc/rtd/topics/datasources/configdrive.rst b/doc/rtd/topics/datasources/configdrive.rst
index f1a488a..f4c5a34 100644
--- a/doc/rtd/topics/datasources/configdrive.rst
+++ b/doc/rtd/topics/datasources/configdrive.rst
@@ -64,7 +64,7 @@ The following criteria are required to as a config drive:
64::64::
6565
66 openstack/66 openstack/
67 - 2012-08-10/ or latest/ 67 - 2012-08-10/ or latest/
68 - meta_data.json68 - meta_data.json
69 - user_data (not mandatory)69 - user_data (not mandatory)
70 - content/70 - content/
@@ -83,7 +83,7 @@ only) file in the following ways.
8383
84::84::
8585
86 dsmode: 86 dsmode:
87 values: local, net, pass87 values: local, net, pass
88 default: pass88 default: pass
8989
@@ -97,10 +97,10 @@ The difference between 'local' and 'net' is that local will not require
97networking to be up before user-data actions (or boothooks) are run.97networking to be up before user-data actions (or boothooks) are run.
9898
99::99::
100 100
101 instance-id:101 instance-id:
102 default: iid-dsconfigdrive102 default: iid-dsconfigdrive
103 103
104This is utilized as the metadata's instance-id. It should generally104This is utilized as the metadata's instance-id. It should generally
105be unique, as it is what is used to determine "is this a new instance".105be unique, as it is what is used to determine "is this a new instance".
106106
@@ -108,18 +108,18 @@ be unique, as it is what is used to determine "is this a new instance".
108108
109 public-keys:109 public-keys:
110 default: None110 default: None
111 111
112If present, these keys will be used as the public keys for the112If present, these keys will be used as the public keys for the
113instance. This value overrides the content in authorized_keys.113instance. This value overrides the content in authorized_keys.
114114
115Note: it is likely preferable to provide keys via user-data115Note: it is likely preferable to provide keys via user-data
116116
117::117::
118 118
119 user-data:119 user-data:
120 default: None120 default: None
121 121
122This provides cloud-init user-data. See :ref:`examples <yaml_examples>` for 122This provides cloud-init user-data. See :ref:`examples <yaml_examples>` for
123what all can be present here.123what all can be present here.
124124
125.. _OpenStack: http://www.openstack.org/125.. _OpenStack: http://www.openstack.org/
diff --git a/doc/rtd/topics/datasources/digitalocean.rst b/doc/rtd/topics/datasources/digitalocean.rst
index 938ede8..88f1e5f 100644
--- a/doc/rtd/topics/datasources/digitalocean.rst
+++ b/doc/rtd/topics/datasources/digitalocean.rst
@@ -20,8 +20,10 @@ DigitalOcean's datasource can be configured as follows:
20 retries: 320 retries: 3
21 timeout: 221 timeout: 2
2222
23- *retries*: Determines the number of times to attempt to connect to the metadata service23- *retries*: Determines the number of times to attempt to connect to the
24- *timeout*: Determines the timeout in seconds to wait for a response from the metadata service24 metadata service
25- *timeout*: Determines the timeout in seconds to wait for a response from the
26 metadata service
2527
26.. _DigitalOcean: http://digitalocean.com/28.. _DigitalOcean: http://digitalocean.com/
27.. _metadata service: https://developers.digitalocean.com/metadata/29.. _metadata service: https://developers.digitalocean.com/metadata/
diff --git a/doc/rtd/topics/datasources/ec2.rst b/doc/rtd/topics/datasources/ec2.rst
index 76beca9..a90f377 100644
--- a/doc/rtd/topics/datasources/ec2.rst
+++ b/doc/rtd/topics/datasources/ec2.rst
@@ -13,7 +13,7 @@ instance metadata.
13Metadata is accessible via the following URL:13Metadata is accessible via the following URL:
1414
15::15::
16 16
17 GET http://169.254.169.254/2009-04-04/meta-data/17 GET http://169.254.169.254/2009-04-04/meta-data/
18 ami-id18 ami-id
19 ami-launch-index19 ami-launch-index
@@ -34,19 +34,20 @@ Metadata is accessible via the following URL:
34Userdata is accessible via the following URL:34Userdata is accessible via the following URL:
3535
36::36::
37 37
38 GET http://169.254.169.254/2009-04-04/user-data38 GET http://169.254.169.254/2009-04-04/user-data
39 1234,fred,reboot,true | 4512,jimbo, | 173,,,39 1234,fred,reboot,true | 4512,jimbo, | 173,,,
4040
41Note that there are multiple versions of this data provided, cloud-init41Note that there are multiple versions of this data provided, cloud-init
42by default uses **2009-04-04** but newer versions can be supported with42by default uses **2009-04-04** but newer versions can be supported with
43relative ease (newer versions have more data exposed, while maintaining43relative ease (newer versions have more data exposed, while maintaining
44backward compatibility with the previous versions). 44backward compatibility with the previous versions).
4545
46To see which versions are supported from your cloud provider use the following URL:46To see which versions are supported from your cloud provider use the following
47URL:
4748
48::49::
49 50
50 GET http://169.254.169.254/51 GET http://169.254.169.254/
51 1.052 1.0
52 2007-01-1953 2007-01-19
diff --git a/doc/rtd/topics/datasources/exoscale.rst b/doc/rtd/topics/datasources/exoscale.rst
index 27aec9c..9074edc 100644
--- a/doc/rtd/topics/datasources/exoscale.rst
+++ b/doc/rtd/topics/datasources/exoscale.rst
@@ -26,8 +26,8 @@ In the password server case, the following rules apply in order to enable the
26"restore instance password" functionality:26"restore instance password" functionality:
2727
28 * If a password is returned by the password server, it is then marked "saved"28 * If a password is returned by the password server, it is then marked "saved"
29 by the cloud-init datasource. Subsequent boots will skip setting the password29 by the cloud-init datasource. Subsequent boots will skip setting the
30 (the password server will return "saved_password").30 password (the password server will return "saved_password").
31 * When the instance password is reset (via the Exoscale UI), the password31 * When the instance password is reset (via the Exoscale UI), the password
32 server will return the non-empty password at next boot, therefore causing32 server will return the non-empty password at next boot, therefore causing
33 cloud-init to reset the instance's password.33 cloud-init to reset the instance's password.
@@ -38,15 +38,15 @@ Configuration
38Users of this datasource are discouraged from changing the default settings38Users of this datasource are discouraged from changing the default settings
39unless instructed to by Exoscale support.39unless instructed to by Exoscale support.
4040
41The following settings are available and can be set for the datasource in system41The following settings are available and can be set for the datasource in
42configuration (in `/etc/cloud/cloud.cfg.d/`).42system configuration (in `/etc/cloud/cloud.cfg.d/`).
4343
44The settings available are:44The settings available are:
4545
46 * **metadata_url**: The URL for the metadata service (defaults to46 * **metadata_url**: The URL for the metadata service (defaults to
47 ``http://169.254.169.254``)47 ``http://169.254.169.254``)
48 * **api_version**: The API version path on which to query the instance metadata48 * **api_version**: The API version path on which to query the instance
49 (defaults to ``1.0``)49 metadata (defaults to ``1.0``)
50 * **password_server_port**: The port (on the metadata server) on which the50 * **password_server_port**: The port (on the metadata server) on which the
51 password server listens (defaults to ``8080``).51 password server listens (defaults to ``8080``).
52 * **timeout**: the timeout value provided to urlopen for each individual http52 * **timeout**: the timeout value provided to urlopen for each individual http
diff --git a/doc/rtd/topics/datasources/nocloud.rst b/doc/rtd/topics/datasources/nocloud.rst
index 1c5cf96..bc96f7f 100644
--- a/doc/rtd/topics/datasources/nocloud.rst
+++ b/doc/rtd/topics/datasources/nocloud.rst
@@ -57,24 +57,24 @@ Given a disk ubuntu 12.04 cloud image in 'disk.img', you can create a
57sufficient disk by following the example below.57sufficient disk by following the example below.
5858
59::59::
60 60
61 ## create user-data and meta-data files that will be used61 ## create user-data and meta-data files that will be used
62 ## to modify image on first boot62 ## to modify image on first boot
63 $ { echo instance-id: iid-local01; echo local-hostname: cloudimg; } > meta-data63 $ { echo instance-id: iid-local01; echo local-hostname: cloudimg; } > meta-data
64 64
65 $ printf "#cloud-config\npassword: passw0rd\nchpasswd: { expire: False }\nssh_pwauth: True\n" > user-data65 $ printf "#cloud-config\npassword: passw0rd\nchpasswd: { expire: False }\nssh_pwauth: True\n" > user-data
66 66
67 ## create a disk to attach with some user-data and meta-data67 ## create a disk to attach with some user-data and meta-data
68 $ genisoimage -output seed.iso -volid cidata -joliet -rock user-data meta-data68 $ genisoimage -output seed.iso -volid cidata -joliet -rock user-data meta-data
69 69
70 ## alternatively, create a vfat filesystem with same files70 ## alternatively, create a vfat filesystem with same files
71 ## $ truncate --size 2M seed.img71 ## $ truncate --size 2M seed.img
72 ## $ mkfs.vfat -n cidata seed.img72 ## $ mkfs.vfat -n cidata seed.img
73 ## $ mcopy -oi seed.img user-data meta-data ::73 ## $ mcopy -oi seed.img user-data meta-data ::
74 74
75 ## create a new qcow image to boot, backed by your original image75 ## create a new qcow image to boot, backed by your original image
76 $ qemu-img create -f qcow2 -b disk.img boot-disk.img76 $ qemu-img create -f qcow2 -b disk.img boot-disk.img
77 77
78 ## boot the image and login as 'ubuntu' with password 'passw0rd'78 ## boot the image and login as 'ubuntu' with password 'passw0rd'
79 ## note, passw0rd was set as password through the user-data above,79 ## note, passw0rd was set as password through the user-data above,
80 ## there is no password set on these images.80 ## there is no password set on these images.
@@ -88,12 +88,12 @@ to determine if this is "first boot". So if you are making updates to
88user-data you will also have to change that, or start the disk fresh.88user-data you will also have to change that, or start the disk fresh.
8989
90Also, you can inject an ``/etc/network/interfaces`` file by providing the90Also, you can inject an ``/etc/network/interfaces`` file by providing the
91content for that file in the ``network-interfaces`` field of metadata. 91content for that file in the ``network-interfaces`` field of metadata.
9292
93Example metadata:93Example metadata:
9494
95::95::
96 96
97 instance-id: iid-abcdefg97 instance-id: iid-abcdefg
98 network-interfaces: |98 network-interfaces: |
99 iface eth0 inet static99 iface eth0 inet static
diff --git a/doc/rtd/topics/datasources/opennebula.rst b/doc/rtd/topics/datasources/opennebula.rst
index 7c0367c..8e7c255 100644
--- a/doc/rtd/topics/datasources/opennebula.rst
+++ b/doc/rtd/topics/datasources/opennebula.rst
@@ -21,7 +21,7 @@ Datasource configuration
21Datasource accepts following configuration options.21Datasource accepts following configuration options.
2222
23::23::
24 24
25 dsmode:25 dsmode:
26 values: local, net, disabled26 values: local, net, disabled
27 default: net27 default: net
@@ -30,7 +30,7 @@ Tells if this datasource will be processed in 'local' (pre-networking) or
30'net' (post-networking) stage or even completely 'disabled'.30'net' (post-networking) stage or even completely 'disabled'.
3131
32::32::
33 33
34 parseuser:34 parseuser:
35 default: nobody35 default: nobody
3636
@@ -46,7 +46,7 @@ The following criteria are required:
46 or have a *filesystem* label of **CONTEXT** or **CDROM**46 or have a *filesystem* label of **CONTEXT** or **CDROM**
472. Must contain file *context.sh* with contextualization variables.472. Must contain file *context.sh* with contextualization variables.
48 File is generated by OpenNebula, it has a KEY='VALUE' format and48 File is generated by OpenNebula, it has a KEY='VALUE' format and
49 can be easily read by bash 49 can be easily read by bash
5050
51Contextualization variables51Contextualization variables
52~~~~~~~~~~~~~~~~~~~~~~~~~~~52~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -57,7 +57,7 @@ the OpenNebula documentation. Where multiple similar variables are
57specified, only first found is taken.57specified, only first found is taken.
5858
59::59::
60 60
61 DSMODE61 DSMODE
6262
63Datasource mode configuration override. Values: local, net, disabled.63Datasource mode configuration override. Values: local, net, disabled.
@@ -75,30 +75,30 @@ Datasource mode configuration override. Values: local, net, disabled.
75Static `network configuration`_.75Static `network configuration`_.
7676
77::77::
78 78
79 HOSTNAME79 HOSTNAME
8080
81Instance hostname.81Instance hostname.
8282
83::83::
84 84
85 PUBLIC_IP85 PUBLIC_IP
86 IP_PUBLIC86 IP_PUBLIC
87 ETH0_IP87 ETH0_IP
8888
89If no hostname has been specified, cloud-init will try to create hostname89If no hostname has been specified, cloud-init will try to create hostname
90from instance's IP address in 'local' dsmode. In 'net' dsmode, cloud-init 90from instance's IP address in 'local' dsmode. In 'net' dsmode, cloud-init
91tries to resolve one of its IP addresses to get hostname.91tries to resolve one of its IP addresses to get hostname.
9292
93::93::
94 94
95 SSH_KEY95 SSH_KEY
96 SSH_PUBLIC_KEY96 SSH_PUBLIC_KEY
9797
98One or multiple SSH keys (separated by newlines) can be specified.98One or multiple SSH keys (separated by newlines) can be specified.
9999
100::100::
101 101
102 USER_DATA102 USER_DATA
103 USERDATA103 USERDATA
104104
@@ -111,7 +111,7 @@ This example cloud-init configuration (*cloud.cfg*) enables
111OpenNebula datasource only in 'net' mode.111OpenNebula datasource only in 'net' mode.
112112
113::113::
114 114
115 disable_ec2_metadata: True115 disable_ec2_metadata: True
116 datasource_list: ['OpenNebula']116 datasource_list: ['OpenNebula']
117 datasource:117 datasource:
@@ -123,17 +123,17 @@ Example VM's context section
123~~~~~~~~~~~~~~~~~~~~~~~~~~~~123~~~~~~~~~~~~~~~~~~~~~~~~~~~~
124124
125::125::
126 126
127 CONTEXT=[127 CONTEXT=[
128 PUBLIC_IP="$NIC[IP]",128 PUBLIC_IP="$NIC[IP]",
129 SSH_KEY="$USER[SSH_KEY] 129 SSH_KEY="$USER[SSH_KEY]
130 $USER[SSH_KEY1] 130 $USER[SSH_KEY1]
131 $USER[SSH_KEY2] ",131 $USER[SSH_KEY2] ",
132 USER_DATA="#cloud-config132 USER_DATA="#cloud-config
133 # see https://help.ubuntu.com/community/CloudInit133 # see https://help.ubuntu.com/community/CloudInit
134 134
135 packages: []135 packages: []
136 136
137 mounts:137 mounts:
138 - [vdc,none,swap,sw,0,0]138 - [vdc,none,swap,sw,0,0]
139 runcmd:139 runcmd:
diff --git a/doc/rtd/topics/datasources/openstack.rst b/doc/rtd/topics/datasources/openstack.rst
index 421da08..8ce2a53 100644
--- a/doc/rtd/topics/datasources/openstack.rst
+++ b/doc/rtd/topics/datasources/openstack.rst
@@ -78,6 +78,7 @@ upgrade packages and install ``htop`` on all instances:
78 {"cloud-init": "#cloud-config\npackage_upgrade: True\npackages:\n - htop"}78 {"cloud-init": "#cloud-config\npackage_upgrade: True\npackages:\n - htop"}
7979
80For more general information about how cloud-init handles vendor data,80For more general information about how cloud-init handles vendor data,
81including how it can be disabled by users on instances, see :doc:`/topics/vendordata`.81including how it can be disabled by users on instances, see
82:doc:`/topics/vendordata`.
8283
83.. vi: textwidth=7884.. vi: textwidth=78
diff --git a/doc/rtd/topics/datasources/smartos.rst b/doc/rtd/topics/datasources/smartos.rst
index cb9a128..be11dfb 100644
--- a/doc/rtd/topics/datasources/smartos.rst
+++ b/doc/rtd/topics/datasources/smartos.rst
@@ -15,7 +15,8 @@ second serial console. On Linux, this is /dev/ttyS1. The data is a provided
15via a simple protocol: something queries for the data, the console responds15via a simple protocol: something queries for the data, the console responds
16responds with the status and if "SUCCESS" returns until a single ".\n".16responds with the status and if "SUCCESS" returns until a single ".\n".
1717
18New versions of the SmartOS tooling will include support for base64 encoded data.18New versions of the SmartOS tooling will include support for base64 encoded
19data.
1920
20Meta-data channels21Meta-data channels
21------------------22------------------
@@ -27,7 +28,7 @@ channels of SmartOS.
2728
28 - per the spec, user-data is for consumption by the end-user, not29 - per the spec, user-data is for consumption by the end-user, not
29 provisioning tools30 provisioning tools
30 - cloud-init entirely ignores this channel other than writting it to disk31 - cloud-init entirely ignores this channel other than writing it to disk
31 - removal of the meta-data key means that /var/db/user-data gets removed32 - removal of the meta-data key means that /var/db/user-data gets removed
32 - a backup of previous meta-data is maintained as33 - a backup of previous meta-data is maintained as
33 /var/db/user-data.<timestamp>. <timestamp> is the epoch time when34 /var/db/user-data.<timestamp>. <timestamp> is the epoch time when
@@ -42,8 +43,9 @@ channels of SmartOS.
42 - <timestamp> is the epoch time when cloud-init ran.43 - <timestamp> is the epoch time when cloud-init ran.
43 - when the 'user-script' meta-data key goes missing, the user-script is44 - when the 'user-script' meta-data key goes missing, the user-script is
44 removed from the file system, although a backup is maintained.45 removed from the file system, although a backup is maintained.
45 - if the script is not shebanged (i.e. starts with #!<executable>), then46 - if the script does not start with a shebang (i.e. starts with
46 or is not an executable, cloud-init will add a shebang of "#!/bin/bash"47 #!<executable>), then or is not an executable, cloud-init will add a
48 shebang of "#!/bin/bash"
4749
48* cloud-init:user-data is treated like on other Clouds.50* cloud-init:user-data is treated like on other Clouds.
4951
@@ -133,7 +135,7 @@ or not to base64 decode something:
133 * base64_all: Except for excluded keys, attempt to base64 decode135 * base64_all: Except for excluded keys, attempt to base64 decode
134 the values. If the value fails to decode properly, it will be136 the values. If the value fails to decode properly, it will be
135 returned in its text137 returned in its text
136 * base64_keys: A comma deliminated list of which keys are base64 encoded.138 * base64_keys: A comma delimited list of which keys are base64 encoded.
137 * b64-<key>:139 * b64-<key>:
138 for any key, if there exists an entry in the metadata for 'b64-<key>'140 for any key, if there exists an entry in the metadata for 'b64-<key>'
139 Then 'b64-<key>' is expected to be a plaintext boolean indicating whether141 Then 'b64-<key>' is expected to be a plaintext boolean indicating whether
diff --git a/doc/rtd/topics/debugging.rst b/doc/rtd/topics/debugging.rst
index e13d915..afcf267 100644
--- a/doc/rtd/topics/debugging.rst
+++ b/doc/rtd/topics/debugging.rst
@@ -68,18 +68,18 @@ subcommands default to reading /var/log/cloud-init.log.
68 00.00100s (modules-final/config-rightscale_userdata)68 00.00100s (modules-final/config-rightscale_userdata)
69 ...69 ...
7070
71* ``analyze boot`` Make subprocess calls to the kernel in order to get relevant 71* ``analyze boot`` Make subprocess calls to the kernel in order to get relevant
72 pre-cloud-init timestamps, such as the kernel start, kernel finish boot, and cloud-init start.72 pre-cloud-init timestamps, such as the kernel start, kernel finish boot, and cloud-init start.
7373
74.. code-block:: shell-session74.. code-block:: shell-session
7575
76 $ cloud-init analyze boot 76 $ cloud-init analyze boot
77 -- Most Recent Boot Record --77 -- Most Recent Boot Record --
78 Kernel Started at: 2019-06-13 15:59:55.80938578 Kernel Started at: 2019-06-13 15:59:55.809385
79 Kernel ended boot at: 2019-06-13 16:00:00.94474079 Kernel ended boot at: 2019-06-13 16:00:00.944740
80 Kernel time to boot (seconds): 5.13535580 Kernel time to boot (seconds): 5.135355
81 Cloud-init start: 2019-06-13 16:00:05.73839681 Cloud-init start: 2019-06-13 16:00:05.738396
82 Time between Kernel boot and Cloud-init start (seconds): 4.79365682 Time between Kernel boot and Cloud-init start (seconds): 4.793656
8383
8484
85Analyze quickstart - LXC85Analyze quickstart - LXC
diff --git a/doc/rtd/topics/dir_layout.rst b/doc/rtd/topics/dir_layout.rst
index 7a6265e..ebd63ae 100644
--- a/doc/rtd/topics/dir_layout.rst
+++ b/doc/rtd/topics/dir_layout.rst
@@ -2,11 +2,12 @@
2Directory layout2Directory layout
3****************3****************
44
5Cloudinits's directory structure is somewhat different from a regular application::5Cloud-init's directory structure is somewhat different from a regular
6application::
67
7 /var/lib/cloud/8 /var/lib/cloud/
8 - data/9 - data/
9 - instance-id 10 - instance-id
10 - previous-instance-id11 - previous-instance-id
11 - datasource12 - datasource
12 - previous-datasource13 - previous-datasource
@@ -35,38 +36,41 @@ Cloudinits's directory structure is somewhat different from a regular applicatio
3536
36 The main directory containing the cloud-init specific subdirectories.37 The main directory containing the cloud-init specific subdirectories.
37 It is typically located at ``/var/lib`` but there are certain configuration38 It is typically located at ``/var/lib`` but there are certain configuration
38 scenarios where this can be altered. 39 scenarios where this can be altered.
3940
40 TBD, describe this overriding more.41 TBD, describe this overriding more.
4142
42``data/``43``data/``
4344
44 Contains information related to instance ids, datasources and hostnames of the previous45 Contains information related to instance ids, datasources and hostnames of
45 and current instance if they are different. These can be examined as needed to46 the previous and current instance if they are different. These can be
46 determine any information related to a previous boot (if applicable).47 examined as needed to determine any information related to a previous boot
48 (if applicable).
4749
48``handlers/``50``handlers/``
4951
50 Custom ``part-handlers`` code is written out here. Files that end up here are written52 Custom ``part-handlers`` code is written out here. Files that end up here are
51 out with in the scheme of ``part-handler-XYZ`` where ``XYZ`` is the handler number (the53 written out with in the scheme of ``part-handler-XYZ`` where ``XYZ`` is the
52 first handler found starts at 0).54 handler number (the first handler found starts at 0).
5355
5456
55``instance``57``instance``
5658
57 A symlink to the current ``instances/`` subdirectory that points to the currently59 A symlink to the current ``instances/`` subdirectory that points to the
58 active instance (which is active is dependent on the datasource loaded).60 currently active instance (which is active is dependent on the datasource
61 loaded).
5962
60``instances/``63``instances/``
6164
62 All instances that were created using this image end up with instance identifier65 All instances that were created using this image end up with instance
63 subdirectories (and corresponding data for each instance). The currently active66 identifier subdirectories (and corresponding data for each instance). The
64 instance will be symlinked the ``instance`` symlink file defined previously.67 currently active instance will be symlinked the ``instance`` symlink file
68 defined previously.
6569
66``scripts/``70``scripts/``
6771
68 Scripts that are downloaded/created by the corresponding ``part-handler`` will end up72 Scripts that are downloaded/created by the corresponding ``part-handler``
69 in one of these subdirectories.73 will end up in one of these subdirectories.
7074
71``seed/``75``seed/``
7276
@@ -77,6 +81,7 @@ Cloudinits's directory structure is somewhat different from a regular applicatio
77 Cloud-init has a concept of a module semaphore, which basically consists81 Cloud-init has a concept of a module semaphore, which basically consists
78 of the module name and its frequency. These files are used to ensure a module82 of the module name and its frequency. These files are used to ensure a module
79 is only ran `per-once`, `per-instance`, `per-always`. This folder contains83 is only ran `per-once`, `per-instance`, `per-always`. This folder contains
80 semaphore `files` which are only supposed to run `per-once` (not tied to the instance id).84 semaphore `files` which are only supposed to run `per-once` (not tied to the
85 instance id).
8186
82.. vi: textwidth=7887.. vi: textwidth=78
diff --git a/doc/rtd/topics/examples.rst b/doc/rtd/topics/examples.rst
index c30d226..62b8ee4 100644
--- a/doc/rtd/topics/examples.rst
+++ b/doc/rtd/topics/examples.rst
@@ -134,7 +134,7 @@ Configure instances ssh-keys
134.. literalinclude:: ../../examples/cloud-config-ssh-keys.txt134.. literalinclude:: ../../examples/cloud-config-ssh-keys.txt
135 :language: yaml135 :language: yaml
136 :linenos:136 :linenos:
137 137
138Additional apt configuration138Additional apt configuration
139============================139============================
140140
diff --git a/doc/rtd/topics/format.rst b/doc/rtd/topics/format.rst
index 74d1fee..7605040 100644
--- a/doc/rtd/topics/format.rst
+++ b/doc/rtd/topics/format.rst
@@ -4,22 +4,24 @@
4User-Data Formats4User-Data Formats
5*****************5*****************
66
7User data that will be acted upon by cloud-init must be in one of the following types.7User data that will be acted upon by cloud-init must be in one of the following
8types.
89
9Gzip Compressed Content10Gzip Compressed Content
10=======================11=======================
1112
12Content found to be gzip compressed will be uncompressed.13Content found to be gzip compressed will be uncompressed.
13The uncompressed data will then be used as if it were not compressed. 14The uncompressed data will then be used as if it were not compressed.
14This is typically useful because user-data is limited to ~16384 [#]_ bytes.15This is typically useful because user-data is limited to ~16384 [#]_ bytes.
1516
16Mime Multi Part Archive17Mime Multi Part Archive
17=======================18=======================
1819
19This list of rules is applied to each part of this multi-part file. 20This list of rules is applied to each part of this multi-part file.
20Using a mime-multi part file, the user can specify more than one type of data.21Using a mime-multi part file, the user can specify more than one type of data.
2122
22For example, both a user data script and a cloud-config type could be specified.23For example, both a user data script and a cloud-config type could be
24specified.
2325
24Supported content-types:26Supported content-types:
2527
@@ -66,7 +68,8 @@ User-Data Script
6668
67Typically used by those who just want to execute a shell script.69Typically used by those who just want to execute a shell script.
6870
69Begins with: ``#!`` or ``Content-Type: text/x-shellscript`` when using a MIME archive.71Begins with: ``#!`` or ``Content-Type: text/x-shellscript`` when using a MIME
72archive.
7073
71.. note::74.. note::
72 New in cloud-init v. 18.4: User-data scripts can also render cloud instance75 New in cloud-init v. 18.4: User-data scripts can also render cloud instance
@@ -83,25 +86,27 @@ Example
83 #!/bin/sh86 #!/bin/sh
84 echo "Hello World. The time is now $(date -R)!" | tee /root/output.txt87 echo "Hello World. The time is now $(date -R)!" | tee /root/output.txt
8588
86 $ euca-run-instances --key mykey --user-data-file myscript.sh ami-a07d95c9 89 $ euca-run-instances --key mykey --user-data-file myscript.sh ami-a07d95c9
8790
88Include File91Include File
89============92============
9093
91This content is a ``include`` file.94This content is a ``include`` file.
9295
93The file contains a list of urls, one per line.96The file contains a list of urls, one per line. Each of the URLs will be read,
94Each of the URLs will be read, and their content will be passed through this same set of rules.97and their content will be passed through this same set of rules. Ie, the
95Ie, the content read from the URL can be gzipped, mime-multi-part, or plain text.98content read from the URL can be gzipped, mime-multi-part, or plain text. If
96If an error occurs reading a file the remaining files will not be read.99an error occurs reading a file the remaining files will not be read.
97100
98Begins with: ``#include`` or ``Content-Type: text/x-include-url`` when using a MIME archive.101Begins with: ``#include`` or ``Content-Type: text/x-include-url`` when using
102a MIME archive.
99103
100Cloud Config Data104Cloud Config Data
101=================105=================
102106
103Cloud-config is the simplest way to accomplish some things107Cloud-config is the simplest way to accomplish some things via user-data. Using
104via user-data. Using cloud-config syntax, the user can specify certain things in a human friendly format. 108cloud-config syntax, the user can specify certain things in a human friendly
109format.
105110
106These things include:111These things include:
107112
@@ -114,9 +119,11 @@ These things include:
114.. note::119.. note::
115 This file must be valid yaml syntax.120 This file must be valid yaml syntax.
116121
117See the :ref:`yaml_examples` section for a commented set of examples of supported cloud config formats.122See the :ref:`yaml_examples` section for a commented set of examples of
123supported cloud config formats.
118124
119Begins with: ``#cloud-config`` or ``Content-Type: text/cloud-config`` when using a MIME archive.125Begins with: ``#cloud-config`` or ``Content-Type: text/cloud-config`` when
126using a MIME archive.
120127
121.. note::128.. note::
122 New in cloud-init v. 18.4: Cloud config dta can also render cloud instance129 New in cloud-init v. 18.4: Cloud config dta can also render cloud instance
@@ -126,25 +133,41 @@ Begins with: ``#cloud-config`` or ``Content-Type: text/cloud-config`` when using
126Upstart Job133Upstart Job
127===========134===========
128135
129Content is placed into a file in ``/etc/init``, and will be consumed by upstart as any other upstart job.136Content is placed into a file in ``/etc/init``, and will be consumed by upstart
137as any other upstart job.
130138
131Begins with: ``#upstart-job`` or ``Content-Type: text/upstart-job`` when using a MIME archive.139Begins with: ``#upstart-job`` or ``Content-Type: text/upstart-job`` when using
140a MIME archive.
132141
133Cloud Boothook142Cloud Boothook
134==============143==============
135144
136This content is ``boothook`` data. It is stored in a file under ``/var/lib/cloud`` and then executed immediately.145This content is ``boothook`` data. It is stored in a file under
137This is the earliest ``hook`` available. Note, that there is no mechanism provided for running only once. The boothook must take care of this itself.146``/var/lib/cloud`` and then executed immediately. This is the earliest ``hook``
138It is provided with the instance id in the environment variable ``INSTANCE_ID``. This could be made use of to provide a 'once-per-instance' type of functionality.147available. Note, that there is no mechanism provided for running only once. The
148boothook must take care of this itself.
139149
140Begins with: ``#cloud-boothook`` or ``Content-Type: text/cloud-boothook`` when using a MIME archive.150It is provided with the instance id in the environment variable
151``INSTANCE_ID``. This could be made use of to provide a 'once-per-instance'
152type of functionality.
153
154Begins with: ``#cloud-boothook`` or ``Content-Type: text/cloud-boothook`` when
155using a MIME archive.
141156
142Part Handler157Part Handler
143============158============
144159
145This is a ``part-handler``: It contains custom code for either supporting new mime-types in multi-part user data, or overriding the existing handlers for supported mime-types. It will be written to a file in ``/var/lib/cloud/data`` based on its filename (which is generated).160This is a ``part-handler``: It contains custom code for either supporting new
146This must be python code that contains a ``list_types`` function and a ``handle_part`` function. 161mime-types in multi-part user data, or overriding the existing handlers for
147Once the section is read the ``list_types`` method will be called. It must return a list of mime-types that this part-handler handles. Because mime parts are processed in order, a ``part-handler`` part must precede any parts with mime-types it is expected to handle in the same user data.162supported mime-types. It will be written to a file in ``/var/lib/cloud/data``
163based on its filename (which is generated).
164
165This must be python code that contains a ``list_types`` function and a
166``handle_part`` function. Once the section is read the ``list_types`` method
167will be called. It must return a list of mime-types that this part-handler
168handles. Because mime parts are processed in order, a ``part-handler`` part
169must precede any parts with mime-types it is expected to handle in the same
170user data.
148171
149The ``handle_part`` function must be defined like:172The ``handle_part`` function must be defined like:
150173
@@ -156,11 +179,13 @@ The ``handle_part`` function must be defined like:
156 # filename = the filename of the part (or a generated filename if none is present in mime data)179 # filename = the filename of the part (or a generated filename if none is present in mime data)
157 # payload = the parts' content180 # payload = the parts' content
158181
159Cloud-init will then call the ``handle_part`` function once before it handles any parts, once per part received, and once after all parts have been handled.182Cloud-init will then call the ``handle_part`` function once before it handles
160The ``'__begin__'`` and ``'__end__'`` sentinels allow the part handler to do initialization or teardown before or after183any parts, once per part received, and once after all parts have been handled.
161receiving any parts.184The ``'__begin__'`` and ``'__end__'`` sentinels allow the part handler to do
185initialization or teardown before or after receiving any parts.
162186
163Begins with: ``#part-handler`` or ``Content-Type: text/part-handler`` when using a MIME archive.187Begins with: ``#part-handler`` or ``Content-Type: text/part-handler`` when
188using a MIME archive.
164189
165Example190Example
166-------191-------
diff --git a/doc/rtd/topics/merging.rst b/doc/rtd/topics/merging.rst
index 5f7ca18..2b5e5da 100644
--- a/doc/rtd/topics/merging.rst
+++ b/doc/rtd/topics/merging.rst
@@ -68,8 +68,10 @@ Cloud-init provides merging for the following built-in types:
68The ``Dict`` merger has the following options which control what is done with68The ``Dict`` merger has the following options which control what is done with
69values contained within the config.69values contained within the config.
7070
71- ``allow_delete``: Existing values not present in the new value can be deleted, defaults to False71- ``allow_delete``: Existing values not present in the new value can be
72- ``no_replace``: Do not replace an existing value if one is already present, enabled by default.72 deleted, defaults to False
73- ``no_replace``: Do not replace an existing value if one is already present,
74 enabled by default.
73- ``replace``: Overwrite existing values with new ones.75- ``replace``: Overwrite existing values with new ones.
7476
75The ``List`` merger has the following options which control what is done with77The ``List`` merger has the following options which control what is done with
@@ -77,7 +79,8 @@ the values contained within the config.
7779
78- ``append``: Add new value to the end of the list, defaults to False.80- ``append``: Add new value to the end of the list, defaults to False.
79- ``prepend``: Add new values to the start of the list, defaults to False.81- ``prepend``: Add new values to the start of the list, defaults to False.
80- ``no_replace``: Do not replace an existing value if one is already present, enabled by default.82- ``no_replace``: Do not replace an existing value if one is already present,
83 enabled by default.
81- ``replace``: Overwrite existing values with new ones.84- ``replace``: Overwrite existing values with new ones.
8285
83The ``Str`` merger has the following options which control what is done with86The ``Str`` merger has the following options which control what is done with
@@ -88,10 +91,13 @@ the values contained within the config.
88Common options for all merge types which control how recursive merging is91Common options for all merge types which control how recursive merging is
89done on other types.92done on other types.
9093
91- ``recurse_dict``: If True merge the new values of the dictionary, defaults to True.94- ``recurse_dict``: If True merge the new values of the dictionary, defaults to
92- ``recurse_list``: If True merge the new values of the list, defaults to False.95 True.
96- ``recurse_list``: If True merge the new values of the list, defaults to
97 False.
93- ``recurse_array``: Alias for ``recurse_list``.98- ``recurse_array``: Alias for ``recurse_list``.
94- ``recurse_str``: If True merge the new values of the string, defaults to False.99- ``recurse_str``: If True merge the new values of the string, defaults to
100 False.
95101
96102
97Customizability103Customizability
diff --git a/doc/rtd/topics/network-config-format-v2.rst b/doc/rtd/topics/network-config-format-v2.rst
index 50f5fa6..7f85755 100644
--- a/doc/rtd/topics/network-config-format-v2.rst
+++ b/doc/rtd/topics/network-config-format-v2.rst
@@ -54,11 +54,11 @@ Physical devices
5454
55: (Examples: ethernet, wifi) These can dynamically come and go between55: (Examples: ethernet, wifi) These can dynamically come and go between
56 reboots and even during runtime (hotplugging). In the generic case, they56 reboots and even during runtime (hotplugging). In the generic case, they
57 can be selected by ``match:`` rules on desired properties, such as name/name57 can be selected by ``match:`` rules on desired properties, such as
58 pattern, MAC address, driver, or device paths. In general these will match58 name/name pattern, MAC address, driver, or device paths. In general these
59 any number of devices (unless they refer to properties which are unique59 will match any number of devices (unless they refer to properties which are
60 such as the full path or MAC address), so without further knowledge about60 unique such as the full path or MAC address), so without further knowledge
61 the hardware these will always be considered as a group.61 about the hardware these will always be considered as a group.
6262
63 It is valid to specify no match rules at all, in which case the ID field is63 It is valid to specify no match rules at all, in which case the ID field is
64 simply the interface name to be matched. This is mostly useful if you want64 simply the interface name to be matched. This is mostly useful if you want
@@ -228,8 +228,8 @@ Example: ::
228228
229**parameters**: *<(mapping)>*229**parameters**: *<(mapping)>*
230230
231Customization parameters for special bonding options. Time values are specified231Customization parameters for special bonding options. Time values are
232in seconds unless otherwise specified.232specified in seconds unless otherwise specified.
233233
234**mode**: *<(scalar)>*234**mode**: *<(scalar)>*
235235
@@ -367,8 +367,8 @@ Example: ::
367367
368**parameters**: <*(mapping)>*368**parameters**: <*(mapping)>*
369369
370Customization parameters for special bridging options. Time values are specified370Customization parameters for special bridging options. Time values are
371in seconds unless otherwise specified.371specified in seconds unless otherwise specified.
372372
373**ageing-time**: <*(scalar)>*373**ageing-time**: <*(scalar)>*
374374

Subscribers

People subscribed via source and target branches