summaryrefslogtreecommitdiff
path: root/cloudinit/sources/DataSourceSmartOS.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Add link to Joyent metadata specification.Daniel Watkins2015-03-251-0/+6
|
* Switch logging from info to debug level.Daniel Watkins2015-03-251-3/+3
|
* Ensure that the serial console is always closed.Daniel Watkins2015-03-251-4/+5
|
* Add logging to JoyentMetadataClient.Daniel Watkins2015-03-251-1/+7
|
* Convert DataSourceSmartOS to use v2 metadata.Daniel Watkins2015-03-251-20/+55
|
* Write and read bytes to/from the SmartOS serial console.Daniel Watkins2015-03-131-2/+3
|
* Respond to review:Barry Warsaw2015-01-271-10/+1
| | | | | | | | - Refactor both the base64 encoding and decoding into utility functions. Also: - Mechanically fix some other broken untested code.
* Trunk merged and ported.Barry Warsaw2015-01-261-19/+6
|\
| * Drop reliance on dmidecode executable.Ben Howard2015-01-141-19/+6
| |
* | * More str/bytes fixes.Barry Warsaw2015-01-261-2/+13
| | | | | | | | * Temporarily skip the MAAS tests in py3 since they need to be ported to oauthlib.
* | Largely merge lp:~harlowja/cloud-init/py2-3 albeit manually because it seemedBarry Warsaw2015-01-211-7/+8
|/ | | | | | to be behind trunk. `tox -e py27` passes full test suite. Now to work on replacing mocker.
* fix(pep8): Fix various pep8 violations and version-lock pep8Jay Faulkner2014-08-261-16/+16
| | | | | | 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.
* SmartOS test: do not require existance of /dev/ttyS1.Scott Moser2014-06-021-2/+8
| | | LP: #1316597
* pep8 and pylintScott Moser2014-02-261-2/+3
|
* SmartOS: do not run on arm as dmidecode causes problemsScott Moser2014-02-261-0/+6
| | | | | | See LP: #1243287 for more information, but the easiest thing to do here is just not run smartos on arm. LP: #1243287
* The symlink of /var/lib/cloud/instance is not created at the time that theBen Howard2014-02-141-3/+4
| | | | datasource for SmartOS runs. This patch creates the instance's directory.
* re-work vendor-data and smartosScott Moser2014-02-131-38/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reduces how much cloud-init is explicitly involved in what "vendor-data" could accomplish. The goal of vendor-data was to provide the vendor with a channel to run arbitrary code that accomodate for their specific platform. Much of those accomodations are currently being done in cloud-init. However, this now moves some of those things to default "vendor-data", instead of cloud-init proper. Basically, now we have an 'sdc:vendor-data' key in the metadata. If that does not exist, then cloud-init will use the default. The default, provides a boothook. That boothook writes a file into /var/lib/cloud/per-boot/ . That file will be both written on every boot and then executed at rc.local time frame (by 'scripts-per-boot'). It will then execute /var/lib/cloud/instance/data/user-script and /var/lib/cloud/instance/data/operator-script if they exist. So, the things that cloud-init is now doing outside of the default vendor-data that I would rather be done in vendor-data is: * managing the population of instance/data/user-script and instance/data/operator-script. These could very easily be done from the boothook, but doing them in cloud-init removes the necessity for having a 'mdata-get' command in the image (or some other way for the boothook script to query the datasource). * managing the LEGACY things.
* Define default vendordata for SmartOS. In absence of a vendordata, use aBen Howard2014-02-131-0/+33
| | | | | default #cloud-config that writes per-boot script that fetches subsequent sdc:operator-scripts and executes it.
* minor changes for pylint, write_boot_content improvement.Scott Moser2014-01-241-7/+6
| | | | | | | | | | | if write_boot_content is given somethign that starts with #!, then there isn't a reason to invoke 'file' to tell us that it starts with shebang. This way, we only run file in 2 cases: a.) binary content (don't really know if that is supported or not) b.) magic "user meant to run this with /bin/bash but couldn't be bothered to type that"
* Make SmartOS script handling self-contained in datasource.Ben Howard2014-01-241-3/+60
|
* Fixed flip-flopped commentBen Howard2014-01-241-9/+9
|
* Fixes for SmartOS datasource (LP: #1272115):Ben Howard2014-01-241-6/+39
| | | | | | | | | 1. fixed conflation of user-data and cloud-init user-data. Cloud-init user-data is now namespaced as 'cloud-init:user-data'. 2. user-scripts are now fetched from the meta-data service each boot and executed as in the scripts directory 3. datacenter name is now namespaced as sdc:datacenter 4. user-scripts should be shebanged if there is no file magic
* Fixed typosBen Howard2014-01-161-1/+1
|
* Added vendordata to SmartOSBen Howard2014-01-091-0/+2
|
* Change SmartOS verb for availability zone (LP: #1249124)Ben Howard2013-11-071-1/+1
|
* trim trailing whitespace on smartos hostname when it came from dmidecode.0.7.3Scott Moser2013-10-071-1/+1
|\ | | | | LP: #1236445
| * Fixed SmartOS hostname whitespace bug (LP: #1236445).Ben Howard2013-10-071-1/+1
|/
* DataSourceSmartOS: remove unnecessary availability_zone attributeScott Moser2013-10-041-7/+0
| | | | | The use of availability-zone or availability_zone is provided by the base classes's behavior.
* Configure SmartOS Datasource to be region awareBen Howard2013-10-031-0/+8
|
* Moved ephemeralX.Y handling from Datasource into the cc_disk_setup, which ↵Ben Howard2013-10-031-3/+1
| | | | makes it cloud agnostic.
* Added ability to define disks via 'ephemeralX.Y'.Ben Howard2013-10-021-3/+6
| | | | | | Modified cc_mounts to identify whether ephermalX is partitioned. Changed datasources for Azure and SmartOS to use 'ephemeralX.Y' format. Added disk remove functionally
* Disable partitioning of ephemeral for SmartOS at request of JoyentBen Howard2013-09-271-1/+1
|
* fix tests small other changesScott Moser2013-09-271-1/+1
| | | | | | | | | | | | | | | | | Also * cloudinit/sources/DataSourceAzure.py: invalid xml in a file called 'ovfenv.xml' should raise BrokenAzureDatasource rather than NonAzureDataSource * cloudinit/sources/DataSourceSmartOS.py: cloudinit/sources/DataSourceAzure.py use 'ephemeral0' as the device name in builtin fs_setup * tests/unittests/test_datasource/test_azure.py: * always patch 'list_possible_azure_ds_devs' as it calls find_devs_with which calls blkid, and dramatically was slowing down tests on my system. * test_user_cfg_set_agent_command_plain: fix this test to not depend on specific format of yaml.dumps(). * test_userdata_arrives: add a test that user-data makes it through
* re-work 'ephemeral_disk' and location of builtin configScott Moser2013-09-261-6/+6
| | | | | | | | | | | | | | | | | Previously we had this 'ephemeral_disk' entry in the datasource config for Azure, and then we also copied some entries into the .cfg for that datasource from the datasource config. Ie, datasource['Azure']['disk_setup'] would be oddly copied into the .cfg object that was returned by 'get_config_obj' Now, instead, we have a BUILTIN_CLOUD_CONFIG, which has those same values in it. The other change here is that 'ephemeral_disk' now has no meaning. Instead, we add a populated-by-default entry 'disk_aliases' to the BUILTIN_DS_CFG, and then just return entries in it for 'device_name_to_device'
* Fixes for the MP.Ben Howard2013-09-191-15/+57
| | | | | | | | | | Changed cc_disk_setup to handle the file systems as a label, no longer passing "log" around. Tidied up the documentation to reflect the changes and made grammer, spelling and improved the content a little. Added disk_setup to the default modules list.
* changes to behavior on specifying keys.Scott Moser2013-08-241-56/+38
| | | | | | | | | | | | | | | | | The most likely end user operation (or at least a valid one) for base64 encoding would be to encode the user-data, but leave all other values as plaintext. In order to facilitate that, the user can simply add: b64-user-data=true to indicate that user-data is base64 encoded. Other changes here are to change the cloud-config and metadata keynames that are used. base64_all = boolean(True) base64_keys = [list, of, keys] Fixed up tests to accomodate.
* Fixed some typos. Change decode_base64 from sys_cfg to ds_cfgBen Howard2013-08-231-1/+4
|
* Fixed no_base64_decode settingsBen Howard2013-08-201-5/+21
|
* Added base64 support to SmartOS datasource.Ben Howard2013-07-301-6/+54
| | | | Added documentation on SmartOS datasource.
* DataSourceSmartOS: fix issue if dmidecode is not presentScott Moser2013-07-241-1/+6
|
* Changed get_serial to be fully parameterized and return the serialBen Howard2013-07-231-29/+35
| | | | | | initialized. Added a mapping of attributes between cloud-init and smartos.
* Move more functionality into get_serial()Ben Howard2013-07-231-15/+27
|
* Added SmartOS datasource and unit tests.Ben Howard2013-07-181-0/+172