Commit Graph

659 Commits (d6f474761dde5e141a371900af9b64f62685dc30)

Author SHA1 Message Date
Monty Taylor 377311db56 Add filter ability 2016-12-08 11:23:14 -05:00
Ed Hein f11c451bfa Fix computation of port bindings. Port bindings configuration can be a list if several host ports are bound to the same guest port. 2016-12-08 11:23:14 -05:00
Davide Guerri c1d7678cc2 Avoind using lookup() in documentation
lookup() is currently broken (current Ansible devel branch), so better to avoid
it in our examples.
2016-12-08 11:23:14 -05:00
Andrew Davis 4d4d911d6e ansible_facts reflects 1.8 output 2016-12-08 11:23:13 -05:00
Monty Taylor 0c0359798b Add OpenStack Keypair module
Also deprecate old nova_keypair module.
2016-12-08 11:23:13 -05:00
Ash Wilson ea83727fcf Wait for process exit on detached=no. 2016-12-08 11:23:13 -05:00
Stefan Junker 4ee972190b docker: Use a list instead of a dict for volumes according to the docker-py docs. Do not add host-binds to volumes list. 2016-12-08 11:23:13 -05:00
Jens Carl 9ad15cdae9 - List the name servers of a zone. 2016-12-08 11:23:13 -05:00
Stefan Junker 50fe57fff3 Fix bind-volumes on docker >= 1.4.0
If bind-volumes are submitted to docker >= 1.4.0 with the volumes set in addition to the binds, docker will create a regular volume and not bind-mount the specified path.
2016-12-08 11:23:13 -05:00
Robb Wagoner e025effc99 include all launch config properties in the return
make all properties available when registering the result
which is useful when wanting to launch a stand-alone instance based upon
an existing Launch Config.
2016-12-08 11:23:12 -05:00
Jonathan Davila 82b809f0e2 new vpc module. does not contain subnet or route table functionality.
changed name to ec2_vpc_net

refactored out IGW functionality
2016-12-08 11:23:12 -05:00
Toshio Kuratomi 0a3150f7d7 Add version_added documentation to log_driver parameter 2016-12-08 11:23:12 -05:00
Michael Weinrich 1f6c177da0 Use aws connect calls that allow boto profile use 2016-12-08 11:23:12 -05:00
Ryan Walls 01a28e7d80 Fix typo in Docker module. 2016-12-08 11:23:12 -05:00
Ryan Walls 9630972c2c Update docker module to avoid false positives when containers are first created. Also have the module check for api compatibility before trying to set a "--log-driver" option. 2016-12-08 11:23:12 -05:00
Ryan Walls f5c1d8141b Set default "log_driver" option to None in docker module. 2016-12-08 11:23:12 -05:00
Ryan Walls 0df1b01cb2 Update docker module to look at log_driver variable when deciding if container configuration has changed. 2016-12-08 11:23:12 -05:00
Ryan Walls 3419a1e253 Add support for --log-driver option that docker released with Docker 1.6 2016-12-08 11:23:12 -05:00
Patrick Roby b318bc8b43 Add support for listing keys in a specific S3 bucket
Includes support for specifying a prefix, marker, and/or max_keys. Returns a list of key names (as strings).
2016-12-08 11:23:11 -05:00
James Cammarata 4239922d07 Updating version_added for new spot_type param in ec2 module
Also made sure 'choices' were set on the module param, to catch errors
in user's playbooks, etc.
2016-12-08 11:23:11 -05:00
Jay Taylor ed279d8175 Added support for spot request type specification (to support persistent spot requests). 2016-12-08 11:23:11 -05:00
zimbatm 99e2557b42 route53: add support for routing policies
It is now possible to pass various routing policies if an identity is
provided.

This commit also introduces multiple optimisations:
* Only fetch records for the given domain
* Use UPSERT instead of DELETE+CREATE to update existing records
2016-12-08 11:23:11 -05:00
billwanjohi 86e679fe3c iam: use modern helper to allow sts
previous implementation ignored the session token when present
2016-12-08 11:23:11 -05:00
James Cammarata 5cd3c6ebe6 Update choices and version_added for new gce.py param service_account_permissions 2016-12-08 11:23:11 -05:00
Michal Smereczynski 9d4b252f56 Added new Premium Storage instance sizes and case-related documentation clarification. 2016-12-08 11:23:11 -05:00
Monty Taylor 186fbd7645 Remove duplicate shade requirement 2016-12-08 11:23:10 -05:00
Monty Taylor 73cb529d2c Make sure we're always returning objects too 2016-12-08 11:23:10 -05:00
dagnello 072110c757 Resolving secgroup.id issue in this module
secgroup['id'] was not being returned in all cases where the
specified security group exists.
2016-12-08 11:23:10 -05:00
toninog bea77c938e fixes to code to enable updates of user to groups and delete groups. Fixed example yaml to use groups 2016-12-08 11:23:10 -05:00
toninog ab7678f199 Fixed more issues with the delete_group and paramater mismatch 2016-12-08 11:23:10 -05:00
Vasyl Kaigorodov 758688a667 GCE module: added Service Account permissions sanity checks 2016-12-08 11:23:10 -05:00
Vasyl Kaigorodov 4400c5e163 GCE module: document Service Account permissions parameter usage 2016-12-08 11:23:10 -05:00
Vasyl Kaigorodov 97e880a27f GCE module: add posibility to specify Service Account permissions during instance creation 2016-12-08 11:23:10 -05:00
Jonathan Davila 6482ad964f iam certificate module
boto import tweak

style patch
2016-12-08 11:23:10 -05:00
Dan Abel a51a8e1fd6 use aws connect calls that allow boto profile use 2016-12-08 11:23:10 -05:00
Vyronas Tsingaras 654d2d3f60 This enable one to find a datastore with no config_target supplied
Signed-off-by: Vyronas Tsingaras <vtsingaras@it.auth.gr>
2016-12-08 11:23:10 -05:00
Vyronas Tsingaras 56957ca45e Remember power state when starting vm reconfigure
This commit fixes #1391

Signed-off-by: Vyronas Tsingaras <vtsingaras@it.auth.gr>
2016-12-08 11:23:10 -05:00
Matt Martz 158772ffc2 Fix some remaining rax asg idempotency checks 2016-12-08 11:23:10 -05:00
Benno Joy 17c185c8d1 enable azure to provision windows instances 2016-12-08 11:23:09 -05:00
Benno Joy 2314670952 enable the module to provision windows instances 2016-12-08 11:23:09 -05:00
Colin Hutchinson 97a2cd0bd9 Indentation fix for with and register in the ec2_vol example 2016-12-08 11:23:09 -05:00
Vyronas Tsingaras bdb33b5756 Properly check if vm_hardware contains keys
This commit fixes #1475

Signed-off-by: Vyronas Tsingaras <vtsingaras@it.auth.gr>
2016-12-08 11:23:09 -05:00
Vyronas Tsingaras 262e86b36b Use either esxi:dc,host OR cluster,resource_pool
vsphere_guest now can deploy a template using a datacenter and hostname
as the target, instead of requiring a cluster and resource_pool.

This commit fixes #951.

Signed-off-by: Vyronas Tsingaras <vtsingaras@it.auth.gr>
2016-12-08 11:23:09 -05:00
Robin Roth abc89f0df5 add comment: ports need to be exposed.
port mapping with this module only works for ports that are exposed either in the Dockerfile or via an additional arguments. This is different from the command line docker client, that is willing to also map ports that are not exposed.

This comments makes the behaviour more obvious.
2016-12-08 11:23:09 -05:00
Monty Taylor 8ff71a3fa8 Actually use changed variable 2016-12-08 11:23:09 -05:00
Monty Taylor 4125b576e9 Return the secgroup for all present states 2016-12-08 11:23:09 -05:00
Monty Taylor b955b2f5c8 Return resource objects from OpenStack modules
It's not uncommon for people to want to do additional things after
creating a module. Also, add a note about it to the dev notes.
2016-12-08 11:23:09 -05:00
Monty Taylor 89f95471f8 Return secgroup, not just id 2016-12-08 11:23:09 -05:00
Philip Kirkland cc214afed6 adding 'encrypted' option into volume dict so ec2 module can easily include encrypted volumes 2016-12-08 11:23:09 -05:00
David Shrewsbury 9cbd7b2ece Remove os_security_group_rule module
The rules module will have it's own branch.
2016-12-08 11:23:08 -05:00
David Shrewsbury 6527f895a1 Remove 'result' value
This value is pretty much useless, and a holdover from the old
module code. Let's remove it.
2016-12-08 11:23:08 -05:00
Monty Taylor eb2f3c8a44 Update version added 2016-12-08 11:23:08 -05:00
David Shrewsbury 7f0da6d851 Update the docstring for os_security_group
Indicate that idempotence is on security group names, and give
an example for updating a security group description.
2016-12-08 11:23:08 -05:00
David Shrewsbury 640dbee643 Update for latest shade API
Shade version 0.7.0 introduces new API methods for creating,
deleting, and updating security groups. Let's use those and
clean up the module.
2016-12-08 11:23:08 -05:00
Jamie Hannaford f969bc0549 Fix get_launch_config var name 2016-12-08 11:23:08 -05:00
Jamie Hannaford 6b9310ecfb Fix attribute name for Auto Scale servers 2016-12-08 11:23:08 -05:00
Julia Kreger d67ba5e25b Updating os_ironic_node module
Updating the os_ironic_node module to the most recent version
including support for power and maintenance states.
2016-12-08 11:23:08 -05:00
Julia Kreger 51149b9643 Updating os_ironic module
Updating os_ironic module to the most recent version accounting for
changes in Ansible devel branch and the shade library since the
original creation of the module.
2016-12-08 11:23:08 -05:00
nitzmahone 548ab163f5 Added choice validation for state arg
fixes traceback on invalid state arg
2016-12-08 11:23:08 -05:00
Greg DeKoenigsberg 4cdd58064d Updated author data for modules 2016-12-08 11:23:08 -05:00
Greg DeKoenigsberg 18ca7aee07 Updating cloud modules with proper github author information 2016-12-08 11:23:07 -05:00
Robert Estelle 8b2327fe3a Fix missing instance_id param in ec2_eip. 2016-12-08 11:23:07 -05:00
Monty Taylor 574bcac277 Add developer docs for the OpenStack modules 2016-12-08 11:23:07 -05:00
Hagai Kariti b154ad4cbb ec2_vol: fix race conditions because we handle errors before actually deleting
Just try to delete the volume and handle the error amazon sends
2016-12-08 11:23:07 -05:00
Tyler Cross 9babe9b07d Get specific object version with S3 module.
- allow specifying version for mode=get and mode=getstr
- when version specified doesn't exist give an error message that indicates so
2016-12-08 11:23:07 -05:00
Monty Taylor 51ce05bfb9 Add Ironic Node module 2016-12-08 11:23:07 -05:00
Monty Taylor e534753092 Add Ironic module 2016-12-08 11:23:07 -05:00
Monty Taylor 0447a88c80 Add OpenStack Object module 2016-12-08 11:23:07 -05:00
Monty Taylor 234a6c93c7 Add OpenStack Security Group support
Two modules - one for security groups and one to manage rules in a
security group.
2016-12-08 11:23:07 -05:00
Robert Estelle ecae3403af Remove unnecessary wait_timeout parameter. 2016-12-08 11:23:07 -05:00
Robert Estelle 3798c8c0ce Refactoring of ec2_eip module. 2016-12-08 11:23:07 -05:00
Robert Estelle 41f7e4ed5e ec2_eip - PEP8 and minor style cleanups. 2016-12-08 11:23:07 -05:00
Robert Estelle a41994974c EC2 Security Group - Validate parameters. 2016-12-08 11:23:07 -05:00
Ching Yi, Chan be9cddbddf Refactoring for easier to read 2016-12-08 11:23:06 -05:00
Ching Yi, Chan 7cafbb5f05 Prevent memory-error from a large file 2016-12-08 11:23:06 -05:00
Soenke Ruempler b57bcac72f Add support for SNS notification ARNs in CloudFormation 2016-12-08 11:23:06 -05:00
Andrea Mandolo adb53cc3c5 Add "block_device_mapping" parameter on EC2_AMI Amazon module (DOCUMENTATION) - upgraded 2016-12-08 11:23:06 -05:00
Bruce Pennypacker 4cb7df2631 Added delobj command to delete an object within a bucket 2016-12-08 11:23:06 -05:00
Alex Gandy 75fa5811db Added volumes dict to ec2_lc example 2016-12-08 11:23:05 -05:00
toninog 15b65fa115 Fixed bug in example where updating a user to a group Fixed bug in create_group and update_group whereby paramaters were not being set correctly. 2016-12-08 11:23:05 -05:00
Monty Taylor 97ce6a500d Update doc params and version_added 2016-12-08 11:23:05 -05:00
Benno Joy f6f2359400 fix for 11177 where module readds rule even if the rules exists 2016-12-08 11:23:05 -05:00
Monty Taylor 29115f0602 AnsibleModule takes a dict as a param 2016-12-08 11:23:05 -05:00
Monty Taylor dbf821ff67 Return a list of OpenStack clouds
The main use of this is to feed jinja templating, so structure the
data returned slightly better for that purpose.
2016-12-08 11:23:05 -05:00
Monty Taylor b87c9002ae Add OpenStack Client Config module
All of the ansible OpenStack modules are driven by a clouds.yaml config
file which is processed by os-client-config. Expose the data returned by
that library to enable playbooks to iterate over available clouds.
2016-12-08 11:23:05 -05:00
Monty Taylor 58942eba2e Use the delete method from shade
Sigh. Turns out glance v1 and glance v2 delete images differently too.
2016-12-08 11:23:05 -05:00
Monty Taylor 8958deeb02 Don't update image properties if we're deleting 2016-12-08 11:23:05 -05:00
Monty Taylor a4e4dbd863 Add OpenStack Image module
Also deprecate old glance_image module
2016-12-08 11:23:05 -05:00
Brian Coca 5ae6f5b767 reverting pep changes that were breaking documentation 2016-12-08 11:23:04 -05:00
Brian Coca 336c22bfd9 made non exec 2016-12-08 11:23:04 -05:00
Tim Mahoney fb3c457122 Elasticache Subnet Group 2016-12-08 11:23:04 -05:00
Monty Taylor 0bc85d461b Add missing state parameter 2016-12-08 11:23:04 -05:00
Sankalp Khare f7055c88de Fixed a typo in ec2_vpc module documentation 2016-12-08 11:23:04 -05:00
billwanjohi ff7dfefbd6 cloudformation: accept local templates in yaml format
Since the YAML data format is a subset of JSON, it is trivial to convert
the former to the latter. This means that we can use YAML templates to
build cloudformation stacks, as long as we translate them before passing
them to the AWS API. I figure this could potentially be quite popular in
the Ansible world, since we already use so much YAML for our playbooks.
2016-12-08 11:23:04 -05:00
James Martin 38d0f31cac Streamlined rolling udpate algorithm. Still need to account for partials, and not waiting for instances if we're mass terminating them. 2016-12-08 11:23:04 -05:00
whiter fc53c2431d Added changed=True flag when new subnet groups created. Added conditional so that modify_db_subnet_group is only called when necessary and changed=True flag will be set. 2016-12-08 11:23:04 -05:00
Jonathan Davila 77fa67a240 author fix 2016-12-08 11:23:04 -05:00
Jonathan Davila d4aff86349 iam_policy 2016-12-08 11:23:04 -05:00
Trevor Pounds 9de952cb3f Instance deregistration should try all associated ELBs. Fixes #869 2016-12-08 11:23:04 -05:00
Trevor Pounds eff6307ac3 Use auto scaling group managed ELBs if present. 2016-12-08 11:23:04 -05:00
Jonathan Davila a329dc05c0 iam module with fixes
iam module. fix policy issue.

bugfix

allow for modifying path without declaring new_path
2016-12-08 11:23:04 -05:00
Raghu Udiyar e6e8f65e92 Creating ami should be idempotent
If the ami already exists, return details of the duplicate
ami instead of failing with an error.
2016-12-08 11:23:04 -05:00
tedder dd6d5f0cb5 feature pull request: catch and retry recoverable errors
boto can throw SSLError when timeouts occur (among other SSL errors). Catch these so proper JSON can be returned, and also add the ability to retry the operation.

There's an open issue in boto for this: https://github.com/boto/boto/issues/2409

Here's a sample stacktrace that inspired me to work on this. I'm on 1.7, but there's no meaningful differences in the 1.8 release that would affect this. I've added line breaks to the trace for readability.

    failed to parse: Traceback (most recent call last):
      File "/home/ubuntu/.ansible/tmp/ansible-tmp-1419895753.17-160808281985012/s3", line 2031, in <module> main()
      File "/home/ubuntu/.ansible/tmp/ansible-tmp-1419895753.17-160808281985012/s3", line 353, in main download_s3file(module, s3, bucket, obj, dest)
      File "/home/ubuntu/.ansible/tmp/ansible-tmp-1419895753.17-160808281985012/s3", line 234, in download_s3file key.get_contents_to_filename(dest)
      File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1665, in get_contents_to_filename response_headers=response_headers)
      File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1603, in get_contents_to_file response_headers=response_headers)
      File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1435, in get_file query_args=None)
      File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1488, in _get_file_internal for bytes in self:
      File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 368, in next data = self.resp.read(self.BufferSize)
      File "/usr/local/lib/python2.7/dist-packages/boto/connection.py", line 416, in read return httplib.HTTPResponse.read(self, amt)
      File "/usr/lib/python2.7/httplib.py", line 567, in read s = self.fp.read(amt)
      File "/usr/lib/python2.7/socket.py", line 380, in read data = self._sock.recv(left)
      File "/usr/lib/python2.7/ssl.py", line 341, in recv return self.read(buflen)
      File "/usr/lib/python2.7/ssl.py", line 260, in read return self._sslobj.read(len) ssl.SSLError: The read operation timed out
2016-12-08 11:23:04 -05:00
Feanil Patel 36dfb78831 Output the Internet Gatewoy id directly instead of in a dict. 2016-12-08 11:23:03 -05:00
Benno Joy 70188fe02a Fixes issue 1197 for s3 module, where the file gets downloaded even if checksums match 2016-12-08 11:23:03 -05:00
Feanil Patel bfb36f0f1f Tell me what the igw id is if we created an igw. 2016-12-08 11:23:03 -05:00
Brian Coca d7bd36a215 Revert "Add deprecated documentation for _quantum_subnet" cause it was already added
This reverts commit 3fa32c4984e3fa839d1188871b2399f184e395a5.
2016-12-08 11:23:03 -05:00
Toshio Kuratomi 8576d1f9d1 Add deprecated documentation for _quantum_subnet 2016-12-08 11:23:03 -05:00
David Shrewsbury 67d8ff197e Rename os_subnet to os_subnet.py 2016-12-08 11:23:03 -05:00
Monty Taylor acdc90f31d Add OpenStack Subnet module
Also deprecated old quantum_subnet module
2016-12-08 11:23:03 -05:00
xiaclo 8715ce07ae Fix issue #1156
Fix as suggested in the issue.

https://github.com/ansible/ansible-modules-core/issues/1156
2016-12-08 11:23:03 -05:00
billwanjohi a6fd78af37 s3 put: add support for server-side encryption
- added 'encrypt' boolean option
- reordered module options alphanumerically
2016-12-08 11:23:02 -05:00
Toshio Kuratomi b6a312e489 Minor fixups found during review of #582 2016-12-08 11:23:02 -05:00
Andrew Pashkin a960caae96 Add 'docker_api_version' to docker_image
By default docker-py uses latest version of Docker API. This is not
always desireable, and this patch adds option to specify version, that
should be used.
2016-12-08 11:23:02 -05:00
whiter d252e7c08f Fix for issue #1332 - when instance is has finished deleting and get_db_instance returns None, exit gracefully 2016-12-08 11:23:01 -05:00
Wang Qiang 86b6f39cf0 Do instance update after add tags to instance. 2016-12-08 11:23:01 -05:00
marko de813195c5 Added support for foreign security groups (Fixes: #373) 2016-12-08 11:23:01 -05:00
Jesse Keating 96b03ce138 Add an openstack servers actions module
This module supports a few of the server actions that are easy to
initially impiment. Other actions require input and provide return
values in the API calls that will be more difficult to impliment, and
thus are not part of this initial commit.
2016-12-08 11:23:01 -05:00
Jonathan Mainguy ce4c9cccf5 fixes example documenation 2016-12-08 11:23:00 -05:00
Monty Taylor eeacb7486d Add OpenStack Network module
Also, deprecate the old quantum network module
2016-12-08 11:23:00 -05:00
Toshio Kuratomi 7e5a4afb6b Update module "imports" to new style
Fixes #1351
2016-12-08 11:23:00 -05:00
Pierre Baillet eba0f12769 Support optional dockerfile name 2016-12-08 11:22:59 -05:00
Benno Joy d24fbf5c3e fixe issue #600, where ec2 module returns instance state as runing even after instance is terminated 2016-12-08 11:22:59 -05:00
whiter 0eb17142b5 Added postgresql-license type 2016-12-08 11:22:59 -05:00
zimbatm 933256fc63 ec2_group: prioritise current VPC group names over others 2016-12-08 11:22:59 -05:00
zimbatm c3e720a393 ec2_group: select own group if the name matches
This fixes an issue where multiple VPC have the same group name and
the one from the other VPC is selected.
2016-12-08 11:22:58 -05:00
Martin Froehlich 8bff781a0a Use get_aws_connection_info to get AWS creds.
Previously used get_ec2_creds did not consider security_token,
making MFA requests fail.
2016-12-08 11:22:58 -05:00
Jan Brauer af689dece3 Handle the case where a stack rollback fails. 2016-12-08 11:22:58 -05:00
Matt Schurenko ef140a084a adding stickiness support to ec2_elb_lb.py
removing policy if enabled is no

adding sanity checks

removing debuging

check if policy exists before deleting

updating version_added to 2.0

adding stickiness support to ec2_elb_lb.py (squashed commit)
2016-12-08 11:22:58 -05:00
Jell 2e007167b9 Find or Create volume by name 2016-12-08 11:22:58 -05:00
Toshio Kuratomi 5336217649 Several cleanups to many modules:
* Fix docs to specify when python2.6+ is required (due to a library
  dep).  This helps us know when it is okay to use python2.6+ syntax in
  the file.
* remove BabyJson returns.  See #1211  This commit fixes all but the
  openstack modules.
* Use if __name__ == '__main__' to only run the main part of the module
  if the module is run as a program.  This allows for the potential to
  unittest the code later.
2016-12-08 11:22:58 -05:00
Chris Lundquist 7b4107a169 fix ami_search doc copy pasta 2016-12-08 11:22:58 -05:00
Benno Joy fc1ad5e1f1 fixes issue 122, where the module recreates the route table in each run 2016-12-08 11:22:58 -05:00
Ratnadeep Debnath a99d7da0c1 Fixed typo in cloud docker module. 2016-12-08 11:22:57 -05:00
Bret Martin b2453bf9a3 ec2_vpc module: add route table resource tagging 2016-12-08 11:22:57 -05:00
Herby Gillot 6a39dc891a Use existing ec2_eip address if already associated
If an EC2 instance is already associated with an EIP address, we use
that, rather than allocating a new EIP address and associating it with
that.

Fixes #35.
2016-12-08 11:22:57 -05:00
(@cewood) 17b5d851f2 Support specifying cidr_ip as a list
Update/fix to Support specifying cidr_ip as a list

Unicode isn't compatible with python2, so we needed some other
solution to this problem. The simplest approach is if the ip item
isn't already a list, simply convert it to one, and we're done.
Thanks to @mspiegle for this suggestion.
2016-12-08 11:22:57 -05:00
Sam Doiron a3ec0a1562 Fix Issue #1216 (ValueError with Amazon RDS)
Fix typo where wrong variable was used, causing ValueError.
2016-12-08 11:22:57 -05:00
Alex Feinberg 1ac9c20b6e Fix a typo in create_instances
Fix a typo in create_instances: use 'placement_group' instead of placement_group
when calling boto_siupports_param_in_spot_request().
2016-12-08 11:22:57 -05:00
Brian Coca fb527955c9 added deprecated doc entry 2016-12-08 11:22:57 -05:00
Toshio Kuratomi c2bf2c7c54 Fix error when container has no names.
Rename loop variable from "i" to more informative "container"

Fixes #1188
2016-12-08 11:22:57 -05:00
David Shrewsbury dd6b153700 Update os_server for shade flavor API changes
Latest shade fixes the flavor API so that raw objects are not
returned.
2016-12-08 11:22:57 -05:00
Chris Meyers cec3c8c209 better timeout logic when deleting vm disks. Python 2.4 safe excepts 2016-12-08 11:22:57 -05:00
Chris Meyers cdcaa2d6a0 correctly delete disks associated with vms 2016-12-08 11:22:57 -05:00
Monty Taylor 78daf52994 Add OpenStack Server module
Also deprecated old nova_compute module
2016-12-08 11:22:56 -05:00
Brian Coca 2e9462aa21 minor doc fixes, set version added for new tags: parameter should Fix #10894 2016-12-08 11:22:56 -05:00
Toshio Kuratomi 8bc34613bc Second try at fixing #1227 -- set e default value earlier 2016-12-08 11:22:56 -05:00
Toshio Kuratomi 030858df67 Return empty list if an image has no repo_tags 2016-12-08 11:22:56 -05:00
Toshio Kuratomi 0d468a3aa0 Get docker's default api version definition from both 1.2 location and pre-1.2 location
Fixes #1227
2016-12-08 11:22:56 -05:00
Brian Coca 018b0118dc removed deprecated docs, not true anymore 2016-12-08 11:22:56 -05:00
Toshio Kuratomi 4592b795d9 Only split on the first colon.
Fixes #1214
2016-12-08 11:22:56 -05:00
Brian Coca b5b34f6931 removed unused and undefined aws_regions 2016-12-08 11:22:56 -05:00
Brian Coca 953ed0aecc avoid exception when boto is not available 2016-12-08 11:22:56 -05:00
Brian Coca 5e892b894b removed redundant region def 2016-12-08 11:22:56 -05:00
David Shrewsbury c29ae705f0 Update os_server_volume for latest shade
The shade volume API was updated to return a dict rather than the
object as returned by cinder.
2016-12-08 11:22:56 -05:00
David Shrewsbury 4ea6bded61 Update os_volume for latest shade
The shade volume API was updated to return a dict rather than the
object as returned by cinder.
2016-12-08 11:22:56 -05:00
mcameron dcb8fa0cb9 Net_id already present, remove unnecessary lookup. 2016-12-08 11:22:55 -05:00
mcameron 1cc057ca97 Valodate fip is on the correct network 2016-12-08 11:22:55 -05:00
mcameron 9f30125876 Adding openstack multiregion support 2016-12-08 11:22:55 -05:00
David Shrewsbury 4699e5b905 Recognize when volume attach/detach is not necessary
Do not attempt to attach an already attached volume.
Likewise, do not attempt to detach a volume that is not
attached.

This version adds support for check mode.
2016-12-08 11:22:55 -05:00
Heikki Partanen ec566d86b3 Add support for extra_hosts to docker module
extra_hosts parameter (maps to --add-host in 'docker run' syntax) is used
to add host-to-ip mappings to the container.
2016-12-08 11:22:55 -05:00
Monty Taylor 63a0c0999a Add OpenStack Volume module 2016-12-08 11:22:55 -05:00
Monty Taylor 15013cde32 Add OpenStack Server facts module 2016-12-08 11:22:55 -05:00
Monty Taylor 522a28b75c Add OpenStack Server Volume module 2016-12-08 11:22:55 -05:00
Bobby Calderwood cd14b8115b Fixes regression introduced by edf1ac1ea6ffd5d44bb2bb62ad320364baf310a3 2016-12-08 11:22:55 -05:00
bw-will-usher efd2cc6089 Fixed MS SQL port number in documentation (1443->1433) per: https://support.microsoft.com/en-us/kb/287932 2016-12-08 11:22:55 -05:00
Romain Dartigues cf86c9b29f Issue #1161 DigitalOcean API 2 ssh_key_ids problem
* fix documentation: show a valid syntax
* make ssh_key_ids a list and not a string
2016-12-08 11:22:55 -05:00
Brian Coca 88e3c19e9a added new ec2_ami_find as per #905 2016-12-08 11:22:54 -05:00
Brian Coca 2733705a19 deprecated ec2_ami_search 2016-12-08 11:22:54 -05:00
sisso 17a409f20d fixed bug where scaling policy return a random policy if many autoscale group have policies with same name. 2016-12-08 11:22:54 -05:00
Jan Brauer 31abdc7ace Add missing comma 2016-12-08 11:22:54 -05:00
Daekwon Kim a22bdd8356 Fix indent of "register" key 2016-12-08 11:22:54 -05:00
Daekwon Kim 4591761c73 Fix typo (volue -> volume) 2016-12-08 11:22:54 -05:00
Jaanus Torp 0f0cb9dc16 Added support for tagging images in ec2_ami.py 2016-12-08 11:22:53 -05:00
Andrey Trubachev ac5b0ca59b Fix mess of ipv6 and ipv4 addresses in private_ip 2016-12-08 11:22:53 -05:00
Kyle Johnson cf61778689 Fix typo in rds_subnet_group.py
aws_connection_kwargs should be aws_connect_kwargs
2016-12-08 11:22:53 -05:00
Matt Martz 0b4fec0a06 Don't use a dict comprehension, be more verbose 2016-12-08 11:22:53 -05:00
Brian Coca 7f618bd787 minor docfixes 2016-12-08 11:22:53 -05:00
Monty Taylor 0283791d5f Add OpenStack Auth module
Use this to pre-auth or to get a copy of the service catalog.
2016-12-08 11:22:53 -05:00
Jesse Rusak 9d93f052c2 Update rds module for RDS2 parameter name change.
boto's rds2 renamed `vpc_security_groups` to `vpc_security_group_ids`
and changed from a list of `VPCSecurityGroupMembership` to just a
list of ids. This accommodates that change when rds2 is being used.
2016-12-08 11:22:53 -05:00
steenzout 67f769d9a6 issue #994: use HAS_BOTO to determine if import was successful: - removed import of sys module. - HAS_BOTO constant to check if import was successful. - trigger a failure when import fails. - removed unnecessary imports. 2016-12-08 11:22:53 -05:00
Richard Tier 0a48d54c1c added version to docstring 2016-12-08 11:22:53 -05:00
Monty Taylor ea809efe7b Revert "Add OpenStack Router Gateway module" 2016-12-08 11:22:52 -05:00
Monty Taylor c4db70a133 Add OpenStack Router Gateway module
Also deprecate old quantum_router_gateway module
2016-12-08 11:22:52 -05:00
Ash Wilson c6b0656c1c Record facts for each changed container. 2016-12-08 11:22:52 -05:00
Brian Coca 7985682c94 added support for postgres9.4 which is now available from amazon 2016-12-08 11:22:52 -05:00
Brian Coca 706db441b4 really fixed docs this time 2016-12-08 11:22:52 -05:00
Brian Coca 2dafff3f97 fixed doc issues on cloudformation 2016-12-08 11:22:52 -05:00
Richard Tier 0c1624f9b7 allow setting header 2016-12-08 11:22:52 -05:00
Tor Åke Fransson 459fd81435 Remove all reference to obsolete client_id and rename api_key to the for v2 more correct api_token 2016-12-08 11:22:52 -05:00
Tor Åke Fransson 02883a460b Make digital_ocean ssh command use API v2 2016-12-08 11:22:52 -05:00
Tor Åke Fransson 5faa882138 WIP: DigitalOcean API version 2 with user_data option 2016-12-08 11:22:52 -05:00
Richard Lander 2091278ff0 azure check for hosted service and vm before creating 2016-12-08 11:22:52 -05:00
Rob Johnson d8af3f3b67 allow both template and template_url parameters 2016-12-08 11:22:52 -05:00
Mick Bass 5de4c053b6 clean rebase of https://github.com/ansible/ansible-modules-core/pull/1024 on a new branch 2016-12-08 11:22:51 -05:00
Brian Coca 4f7bc895d2 removed requirements/boto as it broke documentation as it is duplicated in shared aws fragements 2016-12-08 11:22:51 -05:00
Adam Chainz 21339664ce Make cloudformation module's template argument not required in case of stack deletion 2016-12-08 11:22:51 -05:00
Jonathan Davila de85294d2d allow boto profile use with s3 2016-12-08 11:22:51 -05:00
Lorin Hochstein 5224375a5a Use the correct alias syntax 2016-12-08 11:22:51 -05:00
Lorin Hochstein 17e6be671b ec2 module: add instance_id alias
Create an alias named instance_id for the instance_ids parameter.
2016-12-08 11:22:51 -05:00
Robert Estelle 268763995c ec2_group allow empty rules. 2016-12-08 11:22:51 -05:00
Kohei YOSHIDA f0db5c0cd0 support secure connection on fakes3 2016-12-08 11:22:51 -05:00
Ryan Trauntvein eaa0ce0ceb Specify that "state: reloaded" was added in Ansible 1.9 2016-12-08 11:22:51 -05:00
Scott Miller 751434de9d describe choices in alias documentation 2016-12-08 11:22:51 -05:00
Mick Bass 9980205edc Add support for AWS Security Token Service (temporary credentials) to all AWS cloud modules. 2016-12-08 11:22:51 -05:00
Toshio Kuratomi e710e46ff2 Make lack of boto call fail_json instead of sys.exit
Fixes #994
2016-12-08 11:22:51 -05:00
Brandon W Maister c1571928e5 Make cache_subnet_group default to empty security groups
Since they can't be specified together, it seems like setting the
default to no security groups is the right option.
2016-12-08 11:22:51 -05:00
Tom Wadley ad248376b1 use aws connect call in rds_subnet_group that allows boto profile use 2016-12-08 11:22:50 -05:00
Dan Abel 2250a95638 use simpler ec2_connect ec2 util call
This allows boto profile use
2016-12-08 11:22:50 -05:00
Mick Bass e9a0fad36b add retry with exponential backoff when we receive throttling error code from cloudformation 2016-12-08 11:22:50 -05:00
Brandon W Maister cffb2bdee9 Add `cache_subnet_group` to elasticache module
According to the [docs] cache subnet groups are required inside a VPC.

[docs]: http://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/CacheSubnetGroups.html
2016-12-08 11:22:50 -05:00
Brian Coca 7cd7bad2e8 added patch to workaround some s3 connection faliures 2016-12-08 11:22:50 -05:00
Brian Coca 252df8685a refactrored connection exception handling, added check to see if we actually get a connection before proceeding
Fixes #964
2016-12-08 11:22:50 -05:00
Ash Wilson 2dde45cea9 Only fetch details when necessary. 2016-12-08 11:22:50 -05:00
Ash Wilson 93b620ea8a Compare container images to Config.Image. 2016-12-08 11:22:50 -05:00
Sarah Zelechoski 17334b21ea fix syntax in last example 2016-12-08 11:22:50 -05:00
James Martin 57cf6e8bb4 Re-wording of feature. 2016-12-08 11:22:50 -05:00
Toshio Kuratomi e5149f3b30 Fix review comments from @bcoca in #745 2016-12-08 11:22:50 -05:00
Toshio Kuratomi 5378b5db98 Minor code formatting 2016-12-08 11:22:50 -05:00
Rowan Wookey 04fcfdad2c Fixed group name not being passed to wait_for_new_instances when replacing instances
Fixed group_name not being passed to wait_for_elb
Minor code clean up
2016-12-08 11:22:49 -05:00
moe bd09ebe5b4 Woops, make collect/delete loop more efficient. 2016-12-08 11:22:49 -05:00
moe 5e1e1a4dff Fixes #744.
The following cases work for me now:
- Create new ASG with tags
- Update tags on ASG (create/change/delete)

In short, the module should now work as expected
wrt tagging. The previous code did not work at all
with latest boto for me (serialization errors) and
the logic was buggy anyway; e.g. removed tags
would never get deleted from ec2.
2016-12-08 11:22:49 -05:00
James Martin cadfd56304 check lb for instance healthy and some refactoring of rolling replace functions.
Optionally waiting for new instances to be in viable state on ASG creation/update.

Properly updating properties and terminating group.
2016-12-08 11:22:49 -05:00
Brian Coca 7f8094e977 undeprecated openstack modules as new ones are not making into release 2016-12-08 11:22:49 -05:00
moncho 0156188a54 Update docker.py
Fix typo that prevents use_tls 'encrypt' option from working properly.
2016-12-08 11:22:49 -05:00
Toshio Kuratomi 5262d768e0 Add another valid status from downloading images 2016-12-08 11:22:49 -05:00
nemunaire 7eebab43ae Convert tuple items to string before format 2016-12-08 11:22:49 -05:00
Robert Marsa b7649cc5ca Added multiple allowed ranges. 2016-12-08 11:22:49 -05:00
Julien Syx c676adde0b Fix the issue #931
Checking that the parameter doesn't exist. The old code had a bug when the parameter was 0.
2016-12-08 11:22:49 -05:00
Toshio Kuratomi d5e3abc5d5 Some code cleanup (removed unused variables and imports) 2016-12-08 11:22:49 -05:00
Toshio Kuratomi f892ca5b8f Also use DOCKER_TLS_VERIFY env var to turn on tls verification 2016-12-08 11:22:49 -05:00
Toshio Kuratomi 1bb98542d3 Fix a potential bug in docker pull 2016-12-08 11:22:49 -05:00
Toshio Kuratomi 0ad023a0ac When no use_tls is not specified and no tls parameters are given we need to not attempt tls. 2016-12-08 11:22:49 -05:00
Alex Rowley eeb867daf0 cloud/amazon/s3: update documentation
update description to show that module can do more than just put files into s3
2016-12-08 11:22:48 -05:00
Toshio Kuratomi 2e93f8e9f7 Make state=running work for backwards compatibility with 1.8 2016-12-08 11:22:48 -05:00
Toshio Kuratomi 1946f05baf Fix lookup of parameter name to be pid instead of pid_mode 2016-12-08 11:22:48 -05:00
Toshio Kuratomi 09a0db1e1f Make pid_mode parameter do minimum docker-py/docker server version checks 2016-12-08 11:22:48 -05:00
Toshio Kuratomi 95df4bcbee Fix for problems found by @dguerri
* TLSConfig['verify'] has to be set to False if we're only encrypting the
  connection, not verifying the host.
* tls_hostname was not set if tls_ca_cert was not present

https://github.com/ansible/ansible-modules-core/pull/926#issuecomment-78573877
2016-12-08 11:22:48 -05:00
Toshio Kuratomi 7c261b3954 Implement comments from @smashwilson:
* if tls_ca_cert is set then use tls to verify the server
* take tls_hostname from the environment variable DOCKER_TLS_HOSTNAME
  if it's not specified in the playbook

https://github.com/ansible/ansible-modules-core/pull/926#issuecomment-78542210
2016-12-08 11:22:48 -05:00
Ian Babrou 3bfe9a7b50 fixed: global name 'e' is not defined 2016-12-08 11:22:48 -05:00
Toshio Kuratomi 3284359894 Alternative implementation of tls for docker
Alternative to #854
2016-12-08 11:22:48 -05:00
Toshio Kuratomi c9b33d5de2 Fix for py2.6 (no dict comprehensions on py2.6) 2016-12-08 11:22:48 -05:00
Toshio Kuratomi c9cc8d0b70 Initialize the value of vpc_id variable 2016-12-08 11:22:48 -05:00
Toshio Kuratomi ba90eea165 Also don't fail if files are different and overwrite is false for uploads (this mimics copy and template).
Related to #489
2016-12-08 11:22:48 -05:00
Hagai Kariti 7d16ec283e Fix KeyError in public zones in route53 2016-12-08 11:22:48 -05:00
Toshio Kuratomi a02641b4f3 Documentation style changes 2016-12-08 11:22:48 -05:00
Matt Martz bcd9f83521 Prevent an empty error message 2016-12-08 11:22:48 -05:00
Ian Babrou 005d02b185 not triggering reload for links and not string env variables 2016-12-08 11:22:47 -05:00
Ash Wilson 7c4e8774d8 Use {0}, {1} style format indices for 2.6 compat 2016-12-08 11:22:47 -05:00
Ash Wilson ff0d0ceb70 Expect module env vars to override Dockerfile ones. 2016-12-08 11:22:47 -05:00
Ash Wilson 4e7d766e8f Include bind mounts in VOLUMES check. 2016-12-08 11:22:47 -05:00
Ash Wilson 959d135b60 Exposed ports, env vars, volumes from the image.
This will account for settings that are provided by the hierarchy of
Dockerfiles used to construct your image, rather than only accounting
for settings provided to the module directly.
2016-12-08 11:22:47 -05:00
Ash Wilson 0d822c0c02 Full image inspection and just repo tags
Hat tip to @bobrik.
2016-12-08 11:22:47 -05:00
Toshio Kuratomi bba322a10e Sort subnets by the order they are specified in the play
Fixes #172
2016-12-08 11:22:47 -05:00
Bret Martin 650a7365f9 Allow vpc_subnet_id to remain unspecified (see bc0c169) 2016-12-08 11:22:47 -05:00
Sam Yaple 42fd85f041 Updated version and fixed default 2016-12-08 11:22:47 -05:00
Sam Yaple 24f1cf80bd Add pid mode support to docker module
This allows setting the pid namespace for a container. Currently only
the 'host' pid namespace is supported.

This requires Docker 1.4.1 and docker-py 1.0.0
2016-12-08 11:22:47 -05:00
Ash Wilson 1c5601a0b5 Connect to Docker with optional TLS. 2016-12-08 11:22:47 -05:00
Ash Wilson 4224dd1acb Rework docker module states.
Organize each state into a distinct function for readability and composability.
Rework `present` to create but not start containers. Add a `restarted` state
to unconditionally restart a container and a `reloaded` state to restart a
container if and only if its configuration is incorrect. Store our most recent
knowledge about container states in a ContainerSet object. Improve the value
registered by this task to include not only the inspect data from any changed
containers, but also action counters in their native form, a summary message
for all actions taken, and a `reload_reasons` key to store a human-readable
diagnostic to determine why each container was reloaded.
2016-12-08 11:22:47 -05:00
Matt Ferrante aaca9b5127 check keys is in dim2 before evaluating 2016-12-08 11:22:47 -05:00
Lorin Hochstein 09e10ea031 Don't pass volumes_from to create_container
Don't pass the volumes_from argument to the Docker create_container method.

If the volumes_from argument is passed to the create_container method, Docker
raises the following exception:

    docker.errors.DockerException: 'volumes_from' parameter has no effect on
    create_container(). It has been moved to start()
2016-12-08 11:22:47 -05:00
Ash Wilson 338bbf6efc Pull newer image versions when requested. 2016-12-08 11:22:46 -05:00
Ash Wilson 6505ce3940 Another documentation commit. 2016-12-08 11:22:46 -05:00
Lev Popov 5f31654704 Allow to keep instance boot disk after instance deletion in google cloud module 2016-12-08 11:22:46 -05:00
Toshio Kuratomi 49511ea078 Small code cleanup 2016-12-08 11:22:46 -05:00
Brandon W Maister 2121bbc208 ec2: Apply all security groups at instance-creation
The code was picking out the first instance from the security groups
specified, even when multiple groups were specified. Now we use all of
them.
2016-12-08 11:22:46 -05:00
Lev Popov 6d1fd1afcc Allow to spawn instances without external ip in google cloud module 2016-12-08 11:22:46 -05:00
Michael Laccetti 8efb138fdc Moving the import to the top of the file and getting rid of the redundancy
I sure do wish I knew where the whitespace change was coming from, though. Frustrating.
2016-12-08 11:22:46 -05:00
Michael Laccetti 0bd25a9a38 Change s3 to use connect_to_region
* Allows us to use Ansible/s3 for GovCloud when accessing a pre-existing bucket
2016-12-08 11:22:46 -05:00
Peter Gehres 878ff1e929 Issue #489: s3 should not fail on checksum mismtach when overwrite=no 2016-12-08 11:22:46 -05:00
Achilleas Pipinellis 302c6f9b82 Add note about using version 1 of DigitalOcean API. 2016-12-08 11:22:45 -05:00
Feanil Patel a0caaf7f42 Compare DNS names case insensitively. 2016-12-08 11:22:45 -05:00
James Cammarata 7fd7cffb61 Updating version added fields for new alias parameters in route53 2016-12-08 11:22:45 -05:00
Monty Taylor 3e3486b813 One more OpenStack deprecation notice
Fixes #858
2016-12-08 11:22:45 -05:00
James Cammarata 657d9d1f25 Add private_zone parameter for route53
Fixes #473
2016-12-08 11:22:45 -05:00
Monty Taylor 411c7e22b6 Add deprecation notices for old OpenStack modules 2016-12-08 11:22:45 -05:00
Monty Taylor 7c9a36a999 Deprecate old OpenStack modules
There are a completely new set of modules that do all of the things like
keystone v3 and auth_plugins and the like correctly. Structurally
upgrading these would have been massively disruptive and there is no
real good way to do so without breaking people.

These modules should be kept around for several releases - they still
work for people - and they should get bug fixes. But they should not
take new features. New features should go to the os_ modules.
2016-12-08 11:22:45 -05:00
Brian Coca 5c90040626 undeprecated docker_image until replacement actually arives 2016-12-08 11:22:45 -05:00
Brian Coca 49c10e4359 now captures connection exceptions and returns in 'nicer' module failure 2016-12-08 11:22:44 -05:00
Coderah 0fbe26273d add alias support to route53 module 2016-12-08 11:22:44 -05:00
Coderah 40c41ed4ec add hosted_zone information to ec2_elb_lb return 2016-12-08 11:22:44 -05:00
Capi Etheriel 103caa2853 add ec2 instance tags and groups info 2016-12-08 11:22:44 -05:00
Joel Thompson 646657e325 Fixes issue 697 -- only purge the grants that need to be purged 2016-12-08 11:22:44 -05:00
Jorge-Rodriguez ad9379ad7d Added optional parameter scheduler_hints. 2016-12-08 11:22:44 -05:00
Bret Martin ed3f1a133b ec2: make group only match group names in this VPC 2016-12-08 11:22:43 -05:00
Edward bad5aafd30 Fixes #816 Backups not enabled on new droplets.
Convert backups_enabled string to lowercase. Similar to fix for private
networking.
2016-12-08 11:22:43 -05:00
Brian Coca 70856d5228 fix instance=None documentation 2016-12-08 11:22:43 -05:00
Brian Coca cd7f498755 Revert "Revert "Don't use 'tenancy' in ec2 spot requests"" 2016-12-08 11:22:43 -05:00
Brian Coca 6e55a0324b Revert "Don't use 'tenancy' in ec2 spot requests" 2016-12-08 11:22:43 -05:00
Matt Martz 8e4755728e DRY up duplicate code 2016-12-08 11:22:43 -05:00
Matt Martz cf50526cb5 Don't hardcode minimum for boot_volume_size 2016-12-08 11:22:43 -05:00
Sergey Zhukov d013652dc7 Fixed broken volumes_from for client API >= 1.10 2016-12-08 11:22:43 -05:00
Marek Chodor 35ab6d15df Fixes docker.errors.DockerException: 'dns' parameter has no effect on create_container(). It has been moved to start() 2016-12-08 11:22:43 -05:00
Matt Martz 724ae97898 Fix order of logic to determine required args 2016-12-08 11:22:43 -05:00
Richard Lander a0dad8e683 password required 2016-12-08 11:22:43 -05:00
Richard Lander f5532b7904 set network_config.public_ips attribute 2016-12-08 11:22:43 -05:00
Matt Martz 1f51a5effd Add boot from volume functionality to rax and rax_cbs modules 2016-12-08 11:22:42 -05:00
Matt Martz cce6cb8d7f Don't hardcode a minimum size of a volume 2016-12-08 11:22:42 -05:00
mcameron f799180a58 More general output. 2016-12-08 11:22:42 -05:00
mcameron 751e268f0d Useful log output. 2016-12-08 11:22:42 -05:00