Commit Graph

20 Commits (250b975704603ac5cde3455c0eeb0389f218b815)

Author SHA1 Message Date
Toshio Kuratomi 4b0aa1214c Ziploader
* Ziploader proof of concept (jimi-c)

* Cleanups to proof of concept ziploader branch:

* python3 compatible base64 encoding
* zipfile compression (still need to enable toggling this off for
  systems without zlib support in python)
* Allow non-wildcard imports (still need to make this recusrsive so that
  we can have module_utils code that imports other module_utils code.)
* Better tracebacks: module filename is kept and module_utils directory
  is kept so that tracebacks show the real filenames that the errors
  appear in.

* Make sure we import modules that are used into the module_utils files that they are used in.

* Set ansible version in a more pythonic way for ziploader than we were doing in module replacer

* Make it possible to set the module compression as an inventory var

This may be necessary on systems where python has been compiled without
zlib compression.

* Refactoring of module_common code:

* module replacer only replaces values that make sense for that type of
  file (example: don't attempt to replace python imports if we're in
  a powershell module).
* Implement configurable shebang support for ziploader wrapper
* Implement client-side constants (for SELINUX_SPECIAL_FS and SYSLOG)
  via environment variable.
* Remove strip_comments param as we're never going to use it (ruins line
  numbering)

* Don't repeat ourselves about detecting REPLACER

* Add an easy way to debug

* Port test-module to the ziploader-aware modify_module()

* strip comments and blank lines from the wrapper so we send less over the wire.

* Comments cleanup

* Remember to output write the module line itself in powershell modules

* for line in lines strips the newlines so we have to add them back in
2016-04-05 11:06:17 -07:00
Toshio Kuratomi 3219744d32 One more stdlib import in module_utils 2015-11-02 12:25:18 -08:00
Toshio Kuratomi 1bc75374dc Add imports for stdlib modules that are used.
This is cleanup that will aid us when we get ziploader implemented for 2.1
2015-11-02 12:02:26 -08:00
Matt Martz 4990814901 Prevent an empty error message 2015-03-10 11:30:28 -05:00
Matt Martz cfd05ceafc Add new rax_find_bootable_volume to assist with boot from volume 2015-02-13 15:25:42 -06:00
Matt Martz 047dffdd01 Fix rax_find_loadbalancer issues
* Loadbalancer IDs are not UUIDs
* Ensure found list exists before using it
2014-11-06 16:41:34 -06:00
Matt Martz 55ed4489e3 Perform region validation early to be more explicit about invalid region failures 2014-09-02 09:17:40 -05:00
Matt Martz 7d0eba19ab Dedupe PTR record related code in rax_dns_record 2014-08-06 16:47:33 -05:00
Matt Martz 88acb48753 Add ANSIBLE_VERSION to module_utils/basic.py and manipulate the pyrax user-agent 2014-08-06 16:28:42 -05:00
Matt Martz 585fd5a138 Move additional rackspace common code into module_utils/rax.py 2014-08-06 16:26:48 -05:00
James Cammarata 9730157525 Validate SSL certs accessed through urllib*
* Adds another module utility file which generalizes the
  access of urls via the urllib* libraries.
* Adds a new spec generator for common arguments.
* Makes the user-agent string configurable.

Fixes #6211
2014-03-10 16:06:52 -05:00
Matt Martz ac666e63e0 Support providing a tenant_name also 2014-01-28 13:58:41 -06:00
Matt Martz aa709012ba Make sure to also include the region when using keyring_auth 2014-01-28 13:58:41 -06:00
Matt Martz 021b926235 Only specify to USE_KEYRING as the api_key/password when we actually got a keyring_username from ~/.pyrax.cfg 2014-01-28 13:58:41 -06:00
Matt Martz 1ac7dffd55 Support using ~/.pyrax.cfg and multi environments 2014-01-28 13:58:41 -06:00
Matt Martz 139e905e98 identity_type is set dynamically above 2014-01-28 13:58:41 -06:00
Matt Martz bc473c5be3 Support additional attributes that would allow the rax modules to work with other OpenStack clouds 2014-01-28 13:58:41 -06:00
Matt Martz d7597414b8 Support keyring for the api_key 2014-01-28 13:58:40 -06:00
Matt Martz d46037d64c Do not log the rax api_key argument in module invocation 2014-01-15 16:38:03 -06:00
Matt Martz 3f2cbb7583 Add ansible.module_utils.rax 2013-11-21 15:46:25 -06:00