summaryrefslogtreecommitdiff
path: root/cloudinit/config
AgeCommit message (Collapse)Author
2014-08-26further remove evidence of pylint.Scott Moser
This just removes comments '# pylint:' things and other code remnents of pylint.
2014-08-26fix(pep8): Fix various pep8 violations and version-lock pep8Jay Faulkner
Fixed all complaints from running "make pep8". Also version locked pep8 in test-requirements.txt to ensure that pep8 requirements don't change without an explicit commit.
2014-08-26ssh_authkey_fingerprints: fix bug that prevented disabling the moduleScott Moser
Module intended to allow disabling by configuration, but that was broken. Now this allows: no_ssh_fingerprints = True LP: #1340903
2014-08-21fix rendering resolv.conf if no 'options' are providedScott Moser
this makes some changes to the cc_resolv_conf to make its generate_resolv_conf method more easily callable (for future test). Also sets it up so that 'options' is always defined when the template is rendered. LP: #1328953
2014-07-31ubuntu-init-switch: support disabling of reboot, minor tweeks.Scott Moser
- modify timeout for ~60 seconds before going on. - allow specifying 'reboot' on 'cloud-init single' or in config. - use stdin for subprocess so log is less noisy. - reboot --force: this is required this early in boot for upstart and to my experience at this point always required for systemd
2014-07-31ubuntu-init-switch: fix for determining if systemdScott Moser
/run/systemd/ seems to exist even if systemd is not the init system. but /run/systemd/system/ only exists if it has been used as init.
2014-07-31exit and warn if no 'dpkg' (probably wrong distro)Scott Moser
2014-07-31add some doc to moduleScott Moser
2014-07-31fix path to systemdScott Moser
2014-07-31fix for config, allow specifying target for cloud-init --singleScott Moser
2014-07-31initial commit oif iniit_switchScott Moser
2014-07-29cc_power_state_change: improve TypeError messagesScott Moser
Include the value that was found to be invalid in the error message.
2014-04-01pyflakes cleanupsScott Moser
2014-03-12final_message: allow replacement of capital name keys.Scott Moser
documentation of final_message in doc/examples/cloud-config-final-message.txt showed '$UPTIME' and '$TIMESTAMP' would be available, but only the lower case versions of these strings were available. This change just makes all lower case and upper case keys available here to avoid breaking anyone who used the functional-but-not-correctly-documented lower case names. LP: #1286164
2014-03-03allow random command's output to go throughScott Moser
by default we call 'pollinate -q' which is nice and quiet. if the user wants to be noisy, let them.
2014-03-03cc_seed_random: fix bug and support pollinate commandScott Moser
there was a bug that prevented seeding of /dev/urandom from metadata provided by the datasource unless the user provided random_seed config. This should, instead, be the default behavior.
2014-02-12initial Gentoo and Arch linux supportNate House
2014-02-12merge from trunkScott Moser
2014-02-12Add 'unverified_modules' config option and skip unverified modulesScott Moser
Config modules are able to declare distros that they were verified to run on by setting 'distros' as a list in the config module. Previously, if a module was configured to run and the running distro was not listed as supported, it would run anyway, and a warning would be written. Now, we change the behavior to skip those modules. The distro (or user) can specify that a given list of modules should run anyway by declaring the 'unverified_modules' config variable. run_once modules will be run without this filter (ie, expecting that the user explicitly wanted to run it).
2014-02-12drop 'is_excluded'.Scott Moser
for now, this the mechanism just doesn't seem right. I think i'd rather have the module declare supported distros than have distros declare [un]supported modules.
2014-02-12cc_emit_upstart: do not bother filteringScott Moser
this module should "work" everywhere, in that it will only do anything if /sbin/initctl exists (which is going to be upstart).
2014-02-06Removed exclude conditional on keys-to-consoleNate House nathan.house@rackspace.com
2014-02-06Added arch distro class to merge requestNate House nathan.house@rackspace.com
2014-02-06Removed exclude bits from yum module as its not a defaultNate House nathan.house@rackspace.com
2014-02-05Cleanup and cloud-init-local local/net mount dep fixNate House nathan.house@rackspace.com
2014-02-04Merge gentoo branch and updated set-password to support systemctlNate House nathan.house@rackspace.com
2014-02-03Fix merge conflictNate House nathan.house@rackspace.com
2014-02-03Update yum unittestNate House nathan.house@rackspace.com
2014-01-28exclude modules fix 1Nate House nathan.house@rackspace.com
2014-01-27Removed excessive is_excluded module callsNate House nathan.house@rackspace.com
2014-01-27Adds distro module exclude supportNate House nathan.house@rackspace.com
2014-01-24pylint and long line fixes.Scott Moser
This fixes up many long lines to be < 80 chars and some other pylint issues. pylint 1.1 (in trusty) is now complaining about the lazy logging, so I'll clean that up when I touch things.
2014-01-24init_cmd distro unique supports gentoo init scriptsNate House nathan.house@rackspace.com
2014-01-23Package manager install / update fixes and service restart fooNate House nathan.house@rackspace.com
2014-01-23pep8, use which rather than hard coded pathScott Moser
2014-01-23merge from trunkScott Moser
2014-01-23pep8Scott Moser
2014-01-22cc_resizefs: figure out what /dev/root means via kernel cmdlineScott Moser
If mount_info says that the root filesystem is on /dev/root and /dev/root does not exist, then we'll try to glean that information from the linux kernel cmdline. This situation occurs at least when you boot without an initramfs for the current ppc64el cloud images: qemu-system-ppc64 ... -kernel my.kernel -append 'root=/dev/sda' When doing that, /proc/1/mountinfo will say '/dev/root' for '/'.
2014-01-17merge from trunkScott Moser
2014-01-17remove support for resizing via 'parted resizepart'Scott Moser
This was previously broken anyway. It doesn't seem like there was an easy way to actually support it, so for now I'm removing it entirely. growpart works well enough.
2014-01-15replace get_nested_option_as_list with get_cfg_by_path, improve rupartsScott Moser
this makes runparts take exe_prefix and do string to list conversion inside. that means we don't have to do it in cc_scripts_vendor. Also, get_nested_option_as_list was essentially get_cfg_by_path anyway.
2014-01-15remove vendor-scripts-per-{boot,instance,once}Scott Moser
I don't see a real need for these. The intent of the 'per-boot' or 'per-instance' or 'per-once' config modules is to handle running scripts that were already inserted into the instance. If the vendor is doing that, then there is value in vendor-data. Ie, they'd already modified the image, they might as well have just put the stuff in that they wanted.
2014-01-15header, comment cleanupScott Moser
2014-01-09Merge with upstream sourcesBen Howard
2014-01-08Significant re-working of the userdata handling and introduction ofBen Howard
vendordata. Vendordata is a datasource provided userdata-like blob that is parsed similiarly to userdata, execept at the user's pleasure. cloudinit/config/cc_scripts_vendor.py: added vendor script cloud config cloudinit/config/cc_vendor_scripts_per_boot.py: added vendor per boot cloud config cloudinit/config/cc_vendor_scripts_per_instance.py: added vendor per instance vendor cloud config cloudinit/config/cc_vendor_scripts_per_once.py: added per once vendor cloud config script doc/examples/cloud-config-vendor-data.txt: documentation of vendor-data examples doc/vendordata.txt: documentation of vendordata for vendors (RENAMED) tests/unittests/test_userdata.py => tests/unittests/test_userdata.py TO: tests/unittests/test_userdata.py => tests/unittests/test_data.py: userdata test cases are not expanded to confirm superiority over vendor data. bin/cloud-init: change instances of 'consume_userdata' to 'consume_data' cloudinit/handlers/cloud_config.py: Added vendor script handling to default cloud-config modules cloudinit/handlers/shell_script.py: Added ability to change the path key to support vendor provided 'vendor-scripts'. Defaults to 'script'. cloudinit/helpers.py: - Changed ConfigMerger to include handling of vendordata. - Changed helpers to include paths for vendordata. cloudinit/sources/__init__.py: Added functions for helping vendordata - get_vendordata_raw(): returns vendordata unprocessed - get_vendordata(): returns vendordata through userdata processor - has_vendordata(): indicator if vendordata is present - consume_vendordata(): datasource directive for indicating explict user approval of vendordata consumption. Defaults to 'false' cloudinit/stages.py: Re-jiggered for handling of vendordata - _initial_subdirs(): added vendor script definition - update(): added self._store_vendordata() - [ADDED] _store_vendordata(): store vendordata - _get_default_handlers(): modified to allow for filtering which handlers will run against vendordata - [ADDED] _do_handlers(): moved logic from consume_userdata to _do_handlers(). This allows _consume_vendordata() and _consume_userdata() to use the same code path. - [RENAMED] consume_userdata() to _consume_userdata() - [ADDED] _consume_vendordata() for handling vendordata - run after userdata to get user cloud-config - uses ConfigMerger to get the configuration from the instance perspective about whether or not to use vendordata - [ADDED] consume_data() to call _consume_{user,vendor}data cloudinit/util.py: - [ADDED] get_nested_option_as_list() used by cc_vendor* for getting a nested value from a dict and returned as a list - runparts(): added 'exe_prefix' for running exe with a prefix, used by cc_vendor* config/cloud.cfg: Added vendor script execution as default tests/unittests/test_runs/test_merge_run.py: changed consume_userdata() to consume_data() tests/unittests/test_runs/test_simple_run.py: changed consume_userdata() to consume_data()
2013-12-14change: Just run the required command and let the exception do the restHarm Weites
if the process died. Checking first if the process is still alive proofed to be quite error prone, atleast on a rather slow compute node.
2013-12-14fix: Proper comment.Harm Weites
2013-12-14change: Use a proper signal instead of 'just' 0.Harm Weites
2013-12-14change: Use util.system_info().Harm Weites
2013-12-14new: Touch a reboot-required file to make clear we want a reboot afterHarm Weites
resizing the partition.