From 2b35f6b814b7f30ceea1e8a58c928f2818bb2729 Mon Sep 17 00:00:00 2001 From: Dustin Kirkland Date: Mon, 3 Mar 2014 16:44:31 -0500 Subject: seed_random: support a 'command' to seed /dev/random This extends 'random_seed' top level entry to include a 'command' entry, that has the opportunity to then seed the random number generator. Example config: #cloud-config random_seed: command: ['dd', 'if=/dev/zero', 'of=/dev/random', 'bs=1M', 'count=10'] LP: #1286316 --- ChangeLog | 2 ++ 1 file changed, 2 insertions(+) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 76ab88c4..a45ab73b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -33,6 +33,8 @@ rather than relying on EC2 data in openstack metadata service. - SmartOS, AltCloud: disable running on arm systems due to bug (LP: #1243287, #1285686) [Oleg Strikov] + - Allow running a command to seed random, default is 'pollinate -q' + (LP: #1286316) [Dustin Kirkland] 0.7.4: - fix issue mounting 'ephemeral0' if ephemeral0 was an alias for a partitioned block device with target filesystem on ephemeral0.1. -- cgit v1.2.3 From 910128e61aa3244e254d9c9c803436a5b9aef93c Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Fri, 30 May 2014 10:26:39 -0400 Subject: open 0.7.6 --- ChangeLog | 2 ++ cloudinit/version.py | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 7e2b761e..74145ae1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,5 @@ +0.7.6: + - open 0.7.6 0.7.5: - open 0.7.5 - Add a debug log message around import failures diff --git a/cloudinit/version.py b/cloudinit/version.py index 3db57235..edb651a9 100644 --- a/cloudinit/version.py +++ b/cloudinit/version.py @@ -20,7 +20,7 @@ from distutils import version as vr def version(): - return vr.StrictVersion("0.7.5") + return vr.StrictVersion("0.7.6") def version_string(): -- cgit v1.2.3 From 2bb228751a223f21296ff9166b42583c670359a5 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Mon, 2 Jun 2014 16:56:31 -0400 Subject: SmartOS test: do not require existance of /dev/ttyS1. LP: #1316597 --- ChangeLog | 1 + cloudinit/sources/DataSourceSmartOS.py | 10 ++++++++-- tests/unittests/test_datasource/test_smartos.py | 1 + 3 files changed, 10 insertions(+), 2 deletions(-) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 2dee548e..c455f469 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,7 @@ - Enable vendordata on CloudSigma datasource (LP: #1303986) - Poll on /dev/ttyS1 in CloudSigma datasource only if dmidecode says we're running on cloudsigma (LP: #1316475) [Kiril Vladimiroff] + - SmartOS test: do not require existance of /dev/ttyS1. [LP: #1316597] 0.7.5: - open 0.7.5 - Add a debug log message around import failures diff --git a/cloudinit/sources/DataSourceSmartOS.py b/cloudinit/sources/DataSourceSmartOS.py index 7c1eb09a..65ec0339 100644 --- a/cloudinit/sources/DataSourceSmartOS.py +++ b/cloudinit/sources/DataSourceSmartOS.py @@ -170,8 +170,9 @@ class DataSourceSmartOS(sources.DataSource): md = {} ud = "" - if not os.path.exists(self.seed): - LOG.debug("Host does not appear to be on SmartOS") + if not device_exists(self.seed): + LOG.debug("No serial device '%s' found for SmartOS datasource", + self.seed) return False uname_arch = os.uname()[4] @@ -274,6 +275,11 @@ class DataSourceSmartOS(sources.DataSource): b64=b64) +def device_exists(device): + """Symplistic method to determine if the device exists or not""" + return os.path.exists(device) + + def get_serial(seed_device, seed_timeout): """This is replaced in unit testing, allowing us to replace serial.Serial with a mocked class. diff --git a/tests/unittests/test_datasource/test_smartos.py b/tests/unittests/test_datasource/test_smartos.py index 45f1708a..f64aea07 100644 --- a/tests/unittests/test_datasource/test_smartos.py +++ b/tests/unittests/test_datasource/test_smartos.py @@ -171,6 +171,7 @@ class TestSmartOSDataSource(helpers.FilesystemMockingTestCase): self.apply_patches([(mod, 'get_serial', _get_serial)]) self.apply_patches([(mod, 'dmi_data', _dmi_data)]) self.apply_patches([(os, 'uname', _os_uname)]) + self.apply_patches([(mod, 'device_exists', lambda d: True)]) dsrc = mod.DataSourceSmartOS(sys_cfg, distro=None, paths=self.paths) return dsrc -- cgit v1.2.3 From 9a61ab153ab9d68fb796650666d4ad6729926685 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Mon, 9 Jun 2014 20:38:09 -0400 Subject: doc: fix user-groups doc to reference plural ssh-authorized-keys LP: #1327065 --- ChangeLog | 2 ++ doc/examples/cloud-config-user-groups.txt | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index c455f469..7a35d324 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,8 @@ - Poll on /dev/ttyS1 in CloudSigma datasource only if dmidecode says we're running on cloudsigma (LP: #1316475) [Kiril Vladimiroff] - SmartOS test: do not require existance of /dev/ttyS1. [LP: #1316597] + - doc: fix user-groups doc to reference plural ssh-authorized-keys + (LP: #1327065) [Joern Heissler] 0.7.5: - open 0.7.5 - Add a debug log message around import failures diff --git a/doc/examples/cloud-config-user-groups.txt b/doc/examples/cloud-config-user-groups.txt index 01548380..31491faf 100644 --- a/doc/examples/cloud-config-user-groups.txt +++ b/doc/examples/cloud-config-user-groups.txt @@ -69,7 +69,7 @@ users: # no-user-group: When set to true, do not create a group named after the user. # no-log-init: When set to true, do not initialize lastlog and faillog database. # ssh-import-id: Optional. Import SSH ids -# ssh-authorized-key: Optional. Add key to user's ssh authorized keys file +# ssh-authorized-keys: Optional. [list] Add keys to user's authorized keys file # sudo: Defaults to none. Set to the sudo string you want to use, i.e. # ALL=(ALL) NOPASSWD:ALL. To add multiple rules, use the following # format. -- cgit v1.2.3