Commit Graph

8069 Commits (710ede41ee55200a3a8b013af746b1aa799c2acd)

Author SHA1 Message Date
Brian Coca cdb5a222c5 restored 'results' filters
tests do not work the same, restoring old filters to keep backwards compat
tests now only implment the new normalized 'tense'
8 years ago
Peter Sprygada 65ea24f4bb adds log message for successful connection and disconnection (#17993)
The network module will now log a message when it connects to a remote host
successfully and specify the transport used.  It will also log a message
when the module discconnect() method is called.
8 years ago
Peter Sprygada 3badb212fb fixes issue in eos shared module for earlier versions of EOS (#17980)
Earlier versions of EOS that do not support config sessions would
create an exception.  This fix will now check if the device supports
sessions and if it doesn't, it will fall back to not using sessions
8 years ago
Toshio Kuratomi 33f5c25f41 Update submodule refs to pickup firewalld fix 8 years ago
Toshio Kuratomi bf3d546d9a Only dispkay failure to use cryptography at a higher verbosity
Fixes #17982
8 years ago
Toshio Kuratomi e5478a212f Update submodule refs 8 years ago
stephane a32e48555d Correct delegated_host_name check
In fb50698da3 a check for delegated_host_name being defined was added. Make this
check safer as it breaks some playbooks.
8 years ago
Bruno Rocha b06fb2022c Fix unbound method call for JSONEncoder (#17970)
* Fix unbound method call for JSONEncoder

The way it is currently it will lead to unbound method error

```python
In [1]: import json

In [2]: json.JSONEncoder.default('object_here')
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-2-872fdacfda50> in <module>()
----> 1 json.JSONEncoder.default('object_here')

TypeError: unbound method default() must be called with JSONEncoder instance as first argument (got str instance instead)

```

But what is really wanted is to let the json module to raise the "is not serializable error" which demands a bounded instance of `JSONEncoder()`

```python
In [3]: json.JSONEncoder().default('object_here')
---------------------------------------------------------------------------
TypeError: 'object_here' is not JSON serializable 

```


BTW: I think it would try to call `.to_json` of object before raising as it is a common pattern.

* Calling JSONEncoder bounded `default` method using super()
8 years ago
Chris Houseknecht 77de83730d Add warnings when installing container type roles 8 years ago
Toshio Kuratomi 9f6bbf8c2f Switch get_config to use a single value_type parameter to determine type.
This is better API as the booleans could conflict with each other.

If the config value is a string, make sure to return it as a text string
rather than a byte string.
8 years ago
Ryan S. Brown 6444992afb Update submodule ref for devel 8 years ago
Pavlo Shchelokovskyy aa1ec8af17 Make interprocess polling interval configurable (#16560)
As recently there was back-and-forth with this hardcoded value
(0.001 -> 0.01 -> 0.005), obviousely the optimal value for it depends on
Ansible usage scanario and is better to be configurable.

This patch adds a new config option in DEFAULT section,
`internal_poll_interval`, with default of 0.001 corresponding to the
value hardcoded in Ansible v2.1.
This config option is then used instead of hardcoded values where
needed.

Related GH issue: 14219
8 years ago
Toshio Kuratomi 9f9a960ceb Update submodules 8 years ago
Toshio Kuratomi 1efe782b46 Refactor parsing of CLI args so that we can modify them in the base class
Implement tag and skip_tag handling in the CLI() class.  Change tag and
skip_tag command line options to be accepted multiple times on the CLI
and add them together rather than overwrite.

* Make it configurable whether to merge or overwrite multiple --tags arguments
* Make the base CLI class an abstractbaseclass so we can implement
  functionality in parse() but still make subclasses implement it.
* Deprecate the overwrite feature of --tags with a message that the
  default will change in 2.4 and go away in 2.5.

* Add documentation for merge_multiple_cli_flags
* Fix galaxy search so its tags argument does not conflict with generic tags
* Unit tests and more integration tests for tags
8 years ago
Strahinja Kustudic 9962245b92 Moves 'statically included' messages to -vv verbosity (#17918) 8 years ago
James Cammarata e26bce5221 Sleep briefly while waiting for pending results to reduce CPU churn 8 years ago
Peter Sprygada 087fb4265f adds new option to get_config to grab config with passwords (#17915)
In order for the config to be returned with vpn passwords, the get_config()
method now supports a keyword arg include=passwords to return the desired
configuration.  This replaces the show_command argument
8 years ago
Adrian Likins 41d6f5c635 out.split('\n') -> out.splitlines() (#17879)
foo.split('\n') is picky about the type of 'foo'.
if 'foo' is a bytes type, then foo.split('\n')
will fail on py3 with:

   TypeError: a bytes-like object is required, not 'str'

The foo.split('\n') change isn't strictly required
when run_command returns native str types, but it
is more idiomatic and conceptually also supports other
line endings.
8 years ago
James Cammarata 0a86ddc251 Move searching for roles in the cur basedir to last
Searching the DEFAULT_ROLES_PATH and the roles basedir should come
before this, and it has been a long standing oversight.

Fixes #17882
8 years ago
Mark Szymanski 3a6743fb54 Allowing hostcolor colours to be set 8 years ago
Brian Coca d9d7e413a5 fixed storing of cwd 8 years ago
Toshio Kuratomi 23305540b4 Make ini parsing slightly more robust
Prior to this commit, the ini parser would fail if the inventory was
not 100% utf-8.  This commit makes this slightly more robust by
omitting full line comments from that requirement.

Fixes #17593
8 years ago
Brian Coca 74b7590211 better inventory error messages 8 years ago
James Cammarata d09f57fb3a Check for substates in is_failed before checking main state failure
Fixes #17882
8 years ago
Toshio Kuratomi 08a58ae025 Fix for run_command tests now that it returns native strings 8 years ago
Brian Coca 125a8d3c65 no need for warnings in first_found 8 years ago
Brian Coca 54ce6a9b7a fix for include_role conflating vars/directives 8 years ago
Brian Coca d4b2ea3ec8 include_role process name from options, not task 8 years ago
Toshio Kuratomi 965dcabed2 Update submodule refs for the command fix with new run_command 8 years ago
Adrian Likins d0bdfc2abb Specify run_command decode error style as arg (#17886)
* Specify run_command decode error style as arg

Instead of getting the stdout/stderr text from
run_command, and then decoding to utf-8 with a
particular error scheme, use the 'errors' arg
to run_command so it does that itself.

* Use 'surrogate_or_replace' instead of 'replace'

For the text decoding error scheme in run_command calls.

* Let the local_facts run_command use default errors

* fix typo
8 years ago
Adrian Likins 2addc09050 cast/copy keys() to list to avoid py3 errors
In py3, dict.keys() is a view and not a copy of the
dicts keys, so attempting to delete items from the dict
while iterating over the keys results int

RuntimeError: dictionary changed size during iteration

Resolve by casting .keys() to a list() type.
8 years ago
Adrian Likins 9f673e0725 open anziballs payload 'wb' for py3 8 years ago
Toshio Kuratomi ddd20627a4 Make run_command return native strings
This changes the return value on python3   Return value on python2 was
already byte strings (which is the native str type there.)
8 years ago
Chris Houseknecht ab93d5aae4 Merge pull request #17873 from chouseknecht/fix_3964
Let docker-py decode pull response
8 years ago
James Cammarata 447ab0ab95 Bumping devel version to 2.3.0 8 years ago
Chris Houseknecht fa7e572a96
Let docker-py decode pull response 8 years ago
Matt Davis 64d9de6b25 bump core submodule ref 8 years ago
Brian Coca 49ce0c8bac only change dir to playdir if local
fixes #17869
fixes #17770
8 years ago
Toshio Kuratomi 5bc3cb278c Remove unicode escape (#17866)
* Remove unicode-escape which is not present on python3

Alternative fix for #17305

* Enable the assemble test on python3

* Fix other problems with assemble on python3
8 years ago
Toshio Kuratomi ddb3f91562 Update submodule refs 8 years ago
Guido Günther 14a9bd6a1c Add foreman callback plugin (#17141) 8 years ago
Toshio Kuratomi f72b123584 On python3, subprocess needs another arg to pass extra file descriptors 8 years ago
Toshio Kuratomi 64c446d9c0 Normalize text and byte type in the ssh plugin helper method that builds up an ssh command (#17860)
Mostly cleanups to make the code more efficient, more pythonic, and obey
the unicode sandwich strategy more but also Fixes #17832
8 years ago
Peter Sprygada b0cd624aef fixes issue with run_commands raising error (#17861)
The junos run_commands() method should raise an error when an RpcError is
returned but didn't when using display=text.  This fixes that error
8 years ago
Peter Sprygada 50c445c356 switches the kickstart arg from True to False for eos (#17858)
The kickstart kwarg should be set to False for eos based devices and
was set to True.  This change cleans up problems loading json output
from cli commands

All eos_command test cases are now passing successfully

fixes #17441
8 years ago
Peter Sprygada 512ef49c8a adds new exception for adding condition statements to Conditional (#17859)
When adding condition statements, the Conditional instance will now generate
an AddConditionError if is unable to map the condition to a function in the
instance
8 years ago
Matt Davis a4e5187661 bump core submodule ref for windows async_wrapper bugfix 8 years ago
Matt Davis aa0ad073b8 bugfixes to JSON junk filter, added unit/integration tests to exercise (#17834) 8 years ago
James Cammarata 657506cddd Ensure the "attempts" key is set in the final result for do/until loops
Fixes #17258
8 years ago
Senthil Kumar Ganesan 7e0074263d Remove the dellosX_template module (#17836) 8 years ago
Matt Davis 60b322e3ca bump core submodule ref for async_wrapper fixes 8 years ago
Indrajit Raychaudhuri becb4765c3 Add homebrew in squash_actions list (#16966)
`homebrew`, like other package modules in the existing `squash_actions` list can
benefit from `with_items` loops optimization.
8 years ago
Brian Coca dfff608ceb dzdo prompt fix
fixed tests
dzdo has 2 paths now, with and w/o password
fixes #17838
8 years ago
Brian Coca 6008fbd5cf fix fact gathering flag 8 years ago
Brian Coca 24e81ddd1c add ssh error message to failure 8 years ago
James Cammarata e4ee9de3f4 Fixing parentage of include_role objects for param inheritance
Fixes #17686
8 years ago
Peter Sprygada 6be2f0bded fixes unicode conversation from junos get_config() method (#17841)
The junos config should convert the returning configuration to unicode
not str.  This fixes that issue.
8 years ago
Peter Sprygada 5b4f3b1eda adds better error handling when conditional fails (#17839)
When the conditional cannot extract a value from the result string,
an unhandled exception would be raised.  This fix now gracefully handles
the exception
8 years ago
Peter Sprygada 9faf56a345 fixes issue when calling save_config() and transport is nxapi (#17835)
An unhandled exeception is raised with using nxapi transport and setting
the save argument to true.  This fix will allow the configuration to be
saved regardless of the transport.

fixes ansible/ansible-modules-core#5094
8 years ago
Trond Hindenes 35fba5718d Bugfix: fixes new-alias bug when debugging powershell (#17816) 8 years ago
Makc c6fa701ab1 jabber callback (#16981)
* jabber callback

* delete empty lines

* grammar fix

* fix: do not print error when jabber callback disabled

* change callback version 1 -> 2
8 years ago
Chris Houseknecht e6eed3c3db Merge pull request #17818 from chouseknecht/devel
Parse role dependencies consistently
8 years ago
Chris Houseknecht 8300e67cbe Use new YAML syntax in role dependencies. 8 years ago
jctanner fff161f2f6 Smart mode for sftp+scp (#17813)
If the sftp fails, roll over to scp by default. This saves users
from having to know about the scp_if_ssh method when sftp is broken
on the remote host.
8 years ago
Toshio Kuratomi 458990084e Update submodule refs 8 years ago
Peter Sprygada c534f8f9fc fixes conditional processing with junos and xml data structures (#17801)
The conditional processing was failing due for two reasons:

1) The xml to json conversion string was not happening before the runner
   was processing the results
2) The Conditional instance was not parsing conditionals encoded with []

This fix address both issues.
8 years ago
cinerama70 fb50698da3 Graceful error handling when delegate_to host null (#17453) (#17783)
Currently, if the host specified in delegate_to for a task is null,
Ansible will crash with a stack trace. Add a check for this state
and handle the error appropriately.
8 years ago
Brian Coca 3c42651fc7 fixed typo 8 years ago
Gilles Gagniard da5b0c39c9 fixes #16865 : we should properly determine connection type for delegated task first, before overriding remote user for local connections (#17723) 8 years ago
Peter Sprygada 9854644431 adds overwrite kwarg to load_config in junos (#17798)
The junos load_config() method supports operations of overwrite, replace
and merge.  This adds the missing overwrite keyword arg to load_config()
so that action in junos_template can be procesed correctly.
8 years ago
Toshio Kuratomi 17c0f52c96 Update submodules refs 8 years ago
Brian Coca 368497fd14 better handling of host lists (#17781)
* better handling of host lists

fixes #17762

* corrected message

* fixed extras space
8 years ago
Brian Coca 86ea21a73d ansible_play_batch (#17779)
* ansible_play_batch

* added version added
8 years ago
Peter Sprygada 605152e61b raises ValueError exception if conditional is not parsable (#17788)
The Conditional class now raises a ValueError with message if it cannot
correclty parse the passed in conditional.  This makes it easier to
detect issues in modules that specify conditionals.
8 years ago
Matt Clay 670536f685 Revert "Clear the plugin path cache when adding new directories" (#17785)
This reverts commit 5a57313dd7.
8 years ago
James Cammarata 5a57313dd7 Clear the plugin path cache when adding new directories 8 years ago
Matt Clay dce94ec3c6 Update submodule refs. 8 years ago
Matt Davis e7819609ce swallow errors during async polling (#17760)
also use connection reset on exceptions if available (eg, prevent reuse of "stuck" WinRM connections due to reboot/NIC bounce/etc)
8 years ago
Brian Coca cf7822e201 remove bare vars and undefined from lookup lists (#17647)
https://docs.ansible.com/ansible/porting_guide_2.0.html#deprecated
8 years ago
Brian Coca 3550f73837 removed deprecated first available file from tasks (#17643)
https://docs.ansible.com/ansible/porting_guide_2.0.html#deprecated
8 years ago
Brian Coca 1b0b6b4c10 removed deprecated 'bare' templating environment (#17640)
https://docs.ansible.com/ansible/porting_guide_2.0.html#deprecated
8 years ago
Brian Coca 943f4ebccf undefined var should fail 'label' setting (#17675) 8 years ago
Brian Coca f63b8878fd fix delegate_facts (#17736)
code was misplaced when we changed result processing
also cleaned up import and clarified item/label
fixes #17582
8 years ago
Toshio Kuratomi a4fed650e2 Update submodule refs 8 years ago
Toshio Kuratomi eb33ed4219 Update submodule refs (especially to pick up the mount fixes) 8 years ago
Peter Sprygada 9694d60af5 fixes issue where arguments for regexp search() where transposed (#17764)
The arguments for the regex search() function were transposed in the
netcli match() method that caused conditionals to fail. Switched the
arguments to fixe the bug

fixes #17749
8 years ago
Michael Scherer 362b682f1c Add a umask argument to run_command
In order to avoid problem due to race conditions, it is
required to run umask when generating some sensitive files,
such as a TLS key.
8 years ago
Brian Coca 38b975800d removed unused code, added comment explaining
files is really a placeholder for common code for separate service modules, was copy of current service module and this seemed to confuse people so this update should clear that up
8 years ago
Senthil Kumar Ganesan 9d5dff5596 Update OS6 sublevels (#17735) 8 years ago
Toshio Kuratomi bcebfab8e3 Update submodule refs 8 years ago
peter.jang 0d94d39689 fix for rsync protocol support (#16756) 8 years ago
Toshio Kuratomi 0f4c56a697 Update submodule refs to pick up mount fixes 8 years ago
Peter Sprygada aa1e3ef2b5 fixes issue introduced with raw kwarg (#17728)
The raw kwarg was added to return raw output from devices with if the
attempt to convert to json failed.  The change was causing all json
output to be returned raw.  This fixes that issue.
8 years ago
j0hnsmith 4650d8910e Feature/add ansible play hosts all (#17498)
* refactor ignore_limits_and_restrictions

into ignore_limits and ignore_limitations

* add ansible_play_hosts_all

* update docs re ansible_play_hosts_all

* only use play.hosts when is has a value

* replace ansible_play_hosts with ansible_play_hosts_all

* remove unnecessary var
8 years ago
Brian Coca 52bf021904 clarified `omit` intended usage
fixes #13986
8 years ago
nitzmahone f82c693181 bump extras submodule ref 8 years ago
Peter Sprygada 361f3999ea fixes issue where junos shared module was ignoring ssh_keyfile (#17712)
This fixes a problem with the Netconf transport in which the ssh keyfile
wasn't being used if it was defined.  The ref issue is filed against 2.1.1
but have been unable to replicate the problem in that version

ref: ansible/ansible-modules-core#4966
8 years ago
James Cammarata 6666d13654 Add max_passes to the debug strategy override of _process_pending_results
Fixes #17520
8 years ago
jctanner a2547db5b5 ini lookup: add 'type' to the list of known arguments (#17707)
Fixes #16556
8 years ago
Pascal Grange 8b08a28c89 fixes issue #13981: unsafe_writes block appeared too late in the atom… (#17405)
* fixes issue #13981: unsafe_writes block appeared too late in the atomic_move
workflow. This led to errno.EBUSY to not be managed in the context of
issue #!#981

* Reduce changes to fix #13981

* Abstract the unsafe_writes fallback into a helper method.
Explicitly try/except os.rename part of the code and call this helper method.
If the code fails in shutil.copy2 or shutil.move this should not be related to issue #13981
since they write to b_tmp_dest_name.
(as suggested by @abadger)

* Check if unsafe_writes in the caller, not in _unsafe_writes.
That way the function call reads as "Do an unsafe write"
and not as "I think we should do an unsafe_write.
8 years ago
Peter Sprygada 839f908a14 fixes mode on module_utils/dellos9.py (#17682) 8 years ago
Toshio Kuratomi dde7c11713 Update submodule refs 8 years ago
Toshio Kuratomi 8aa8e07d13 Remove _load_hosts() from Play initialization as it's no longer needed and it breaks using extra_vars defining a list for hosts (#17699)
Thanks to @jimi-c for the solution

Fixes #16583
8 years ago
James Cammarata c9d3d2b9a0 Allow for empty source in dwim_path_relative_stack
Fixes #17192
8 years ago
James Cammarata 23651b657e Create a raw lookup for hostvars that does not template the data
When using hostvars to get extra connection-specific vars for connection
plugins, use this raw lookup to avoid prematurely templating all of the
hostvar data (triggering unnecessary lookups).

Fixes #17024
8 years ago
Ondra Machacek 04165fb6c0 Add oVirt support to `ansible/module_utils` module (#17364)
* Add oVirt utility module

This patch add oVirt utility module, which contains helper functions,
for oVirt modules and also shared documentation fragment for oVirt.

* Adjust to Python 2.4

* Fixups

* Add support for poll interval and fixes
8 years ago
Gabriele cfd880dab8 Adding raw check to nxos.py (#17659) 8 years ago
Peter Sprygada 765a76885b fixes issue where config sessions where left behind (#17673)
When using the Cli transport, if the session hung on a command and the
socket timed out, the config session would be left behind.  This change
will allow the shell to try to get control back and remove the config
session, assuming the channel is still open.

fixes ansible/ansible-modules-core#4945
8 years ago
Peter Sprygada 2a908b832c fixes commit confirm check in junos shared module (#17663)
The module didn't perform a commit confirm check which would cause
checking commits to be non idempotent.  This change will fix that problem.
8 years ago
Matt Clay 24c9e047c3 Remove test-docs from module search ignore list. (#17670) 8 years ago
Matt Clay 08e964a9c5 Update submodule refs. 8 years ago
Brian Coca 1e4e188318 changed missing file error to warning for lookups (#16800)
* changed missing file error to warning for lookups

* changed plugins that expected exception

warning will still be displayed, they now work with None value
8 years ago
Toshio Kuratomi 55cbe257cc Update submodule refs to pick up pip fixes 8 years ago
James Cammarata 4dc2bf4815 Take ITERATING_ALWAYS into account when setting failed state in PlayIterator
Fixes #15963
8 years ago
Timothy Appnel 1975a545bd Implements verbose always to assert action plugin module (#17654) 8 years ago
Toshio Kuratomi a683256342 Update core submodule ref for pip fix 8 years ago
James Cammarata 1b54d3b6dc Merge branch 'threaded_receiver' into devel 8 years ago
Toshio Kuratomi 2f6ab44c76 Update sumodule refs 8 years ago
Peter Sprygada 547cea556f remove old imports from junos shared module (#17655)
this cleans up the old import mechanisms in the junos shared module
8 years ago
Peter Sprygada 433a0e1e40 allow netcfg to pass kwargs from __call__ to configure() (#17653)
This minor fix allows kwargs to pass from Config __call__ to the underlying
transport instance.
8 years ago
Peter Sprygada 6fc9ffd28e clean up junos shared module (#17652)
This cleans up the junos module removing some unneeded commands and fixing
method signature with unneeded **kwargs
8 years ago
Peter Sprygada 662008115b Merge pull request #17651 from skg-net/bugfix
Fix to handle the prompt on saving startup config
8 years ago
Matt Clay 5f72bae3b0 Update submodule refs. 8 years ago
Matt Clay ded45fb535 Update submodule refs. 8 years ago
Senthil Kumar Ganesan 081730851c Fix to handle the prompt on saving startup config 8 years ago
Matt Clay 42a2875b83 Update submodule refs. 8 years ago
James Cammarata 1d2e1a5648 Do not set run_once for meta noop tasks
Fixes #17581
8 years ago
Toshio Kuratomi e3451be457 Update submodule refs 8 years ago
Peter Sprygada b38181116b Merge pull request #17638 from privateip/fix-netcli
fixes issue where netcli would cause exception with an invalid conditional
8 years ago
Toshio Kuratomi 5e9a8d9202 Fix password lookup py3 plus alikins unittest additions refactoring (#17626)
* Improve unit testing of 'password' lookup

The tests showed some UnicodeErrors for the
cases where the 'chars' param include unicode,
causing the 'getattr(string, c, c)' to fail.
So the candidate char generation code try/excepts
UnicodeErrors there now.

Some refactoring of the password.py module to make
it easier to test, and some new tests that cover more
of the password and salt generation.

* More refactoring and fixes.

* manual merge of text enc fixes from pr17475

* moving methods to module scope

* more refactoring

* A few more text encoding fixes/merges

* remove now unused code

* Add test cases and data for _gen_candidate_chars

* more test coverage for password lookup

* wip

* More text encoding fixes and test coverage

* cleanups

* reenable text_type assert

* Remove unneeded conditional in _random_password

* Add docstring for _gen_candidate_chars

* remove redundant to_text and list comphenesion

* Move set of 'chars' default in _random_password

on py2, C.DEFAULT_PASSWORD_CHARS is a regular str
type, so the assert here fails. Move setting the
default into the method and to_text(DEFAULT_PASSWORD_CHARS)
if it's needed.

* combine _random_password and _gen_password

* s/_create_password_file/_create_password_file_dir

* native strings for exception msgs

* move password to_text to _read_password_file

* move to_bytes(content) to _write_password_file

* add more test assertions about genned pw's

* Some cleanups to alikins and abadger's password lookup refactoring:

* Make DEFAULT_PASSWORD_CHARS into a text string in constants.py
  - Move this into the nonconfigurable section of constants.
* Make utils.encrypt.do_encrypt() return a text string because all the
  hashes in passlib should be returning ascii-only strings and they are
  text strings in python3.
* Make the split up of functions more sane:
   - Don't split such that conditionals have to occur in two separate functions.
   - Don't go overboard: Good to split file system manipulation from parsing
     but we don't need to do every file manipulation in a separate
     function.
  - Don't split so that creation of the password store happens in two
    parts.
  - Don't split in such a way that no decisions are made in run.
* Organize functions by when it gets called from run().
* Run all potential characters through the gen_candidate_chars function
  because it does both normalization and validation.
* docstrings for functions
* Change when we store salt slightly.  Store it whenever it was already
  present in the file as well as when encrypt is requested.  This will
  head of potential idempotence bugs where a user has two playbook tasks
  using the same password and in one they need it encrypted but in the
  other they need it plaintext.
* Reorganize tests to follow the order of the functions so it's easier
  to figure out if/where a function has been tested.
* Add tests for the functions that read and write the password file.
* Add tests of run() when the password has already been created.
* Test coverage currently at 100%
8 years ago
Peter Sprygada 1a8ad2a20f fixes issue where netcli would cause exception with an invalid conditional
The Conditional instance will cause a stack trace if the provided conditional
does not map properly to the response.  This fixes that issue so that the
Conditional instance will now raise a FailedConditionalError with the
conditional that caused the failure.

Modules *_command modules (and any other modules that create an instance
of Conditional) should be updated to catch the FailedConditionalError
exception.
8 years ago
Brian Coca a87a239124 draft of return common fields
(cherry picked from commit da2da568a051d51edd8c25a4d324089f8bd616eb)
8 years ago
fallencliff 06d46a1ecc update facts.py for aix (#17539)
* update facts.py for aix

add product_serial ,lpar_info,product_name and pv/vg info into facts

10.223.219.10 | SUCCESS => {
    "ansible_facts": {
        "ansible_all_ipv4_addresses": [
            "77.77.77.1", 
            "10.223.219.10"
        ], 
        "ansible_all_ipv6_addresses": [
            "::1%1/0"
        ], 
        "ansible_architecture": "chrp", 
        "ansible_date_time": {
            "date": "2016-09-13", 
            "day": "13", 
            "epoch": "1473760269", 
            "hour": "17", 
            "iso8601": "2016-09-13T09:51:09Z", 
            "iso8601_basic": "20160913T175109568670", 
            "iso8601_basic_short": "20160913T175109", 
            "iso8601_micro": "2016-09-13T09:51:09.569251Z", 
            "minute": "51", 
            "month": "09", 
            "second": "09", 
            "time": "17:51:09", 
            "tz": "BEIST", 
            "tz_offset": "BEIST", 
            "weekday": "Tuesday", 
            "weekday_number": "2", 
            "weeknumber": "37", 
            "year": "2016"
        }, 
        "ansible_default_ipv4": {
            "address": "10.223.219.10", 
            "broadcast": "10.223.219.127", 
            "device": "en3", 
            "flags": [
                "UP", 
                "BROADCAST", 
                "NOTRAILERS", 
                "RUNNING", 
                "SIMPLEX", 
                "MULTICAST", 
                "GROUPRT", 
                "64BIT", 
                "CHECKSUM_OFFLOAD(ACTIVE)", 
                "LARGESEND", 
                "CHAIN"
            ], 
            "gateway": "10.223.219.1", 
            "interface": "en3", 
            "macaddress": "00:11:25:be:4b:75", 
            "mtu": "1400", 
            "netmask": "255.255.255.128", 
            "network": "10.223.219.0", 
            "type": "unknown"
        }, 
        "ansible_default_ipv6": {}, 
        "ansible_distribution": "AIX", 
        "ansible_distribution_release": "1", 
        "ansible_distribution_version": "6", 
        "ansible_dns": {}, 
        "ansible_domain": "", 
        "ansible_en0": {
            "device": "en0", 
            "flags": [
                "UP", 
                "BROADCAST", 
                "NOTRAILERS", 
                "RUNNING", 
                "SIMPLEX", 
                "MULTICAST", 
                "GROUPRT", 
                "64BIT", 
                "CHECKSUM_OFFLOAD(ACTIVE)", 
                "LARGESEND", 
                "CHAIN"
            ], 
            "ipv4": [
                {
                    "address": "77.77.77.1", 
                    "broadcast": "77.77.77.127", 
                    "netmask": "255.255.255.128", 
                    "network": "77.77.77.0"
                }
            ], 
            "ipv6": [], 
            "macaddress": "00:14:5e:b8:cd:a6", 
            "mtu": "1500", 
            "type": "unknown"
        }, 
        "ansible_en3": {
            "device": "en3", 
            "flags": [
                "UP", 
                "BROADCAST", 
                "NOTRAILERS", 
                "RUNNING", 
                "SIMPLEX", 
                "MULTICAST", 
                "GROUPRT", 
                "64BIT", 
                "CHECKSUM_OFFLOAD(ACTIVE)", 
                "LARGESEND", 
                "CHAIN"
            ], 
            "ipv4": [
                {
                    "address": "10.223.219.10", 
                    "broadcast": "10.223.219.127", 
                    "netmask": "255.255.255.128", 
                    "network": "10.223.219.0"
                }
            ], 
            "ipv6": [], 
            "macaddress": "00:11:25:be:4b:75", 
            "mtu": "1400", 
            "type": "unknown"
        }, 
        "ansible_env": {
            "AUTHSTATE": "compat", 
            "CLCMD_PASSTHRU": "1", 
            "HOME": "/home/yd_hzj", 
            "LANG": "C", 
            "LC_ALL": "C", 
            "LC_MESSAGES": "C", 
            "LC__FASTMSG": "true", 
            "LOCPATH": "/usr/lib/nls/loc", 
            "LOGIN": "yd_hzj", 
            "LOGNAME": "yd_hzj", 
            "MAIL": "/var/spool/mail/yd_hzj", 
            "NLSPATH": "/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat", 
            "ODMDIR": "/etc/objrepos", 
            "PATH": "/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java14/jre/bin:/usr/java14/bin", 
            "PWD": "/home/yd_hzj", 
            "PYTHONPATH": "", 
            "SHELL": "/usr/bin/ksh", 
            "SSH_CLIENT": "10.223.172.41 33369 22", 
            "SSH_CONNECTION": "10.223.172.41 33369 10.223.219.10 22", 
            "SSH_TTY": "/dev/pts/12", 
            "TERM": "vt100", 
            "TZ": "BEIST-8", 
            "USER": "yd_hzj", 
            "_": "/usr/bin/python"
        }, 
        "ansible_fips": false, 
        "ansible_firmware_version": "SF240_358", 
        "ansible_fqdn": "test1", 
        "ansible_gather_subset": [
            "hardware", 
            "network", 
            "virtual"
        ], 
        "ansible_hostname": "test1", 
        "ansible_interfaces": [
            "en0", 
            "lo0", 
            "en3"
        ], 
        "ansible_kernel": "1", 
        "ansible_lo0": {
            "device": "lo0", 
            "flags": [
                "UP", 
                "BROADCAST", 
                "LOOPBACK", 
                "RUNNING", 
                "SIMPLEX", 
                "MULTICAST", 
                "GROUPRT", 
                "64BIT", 
                "LARGESEND", 
                "CHAIN"
            ], 
            "ipv4": [
                {
                    "address": "127.0.0.1", 
                    "broadcast": "127.255.255.255", 
                    "netmask": "255.0.0.0", 
                    "network": "127.0.0.0"
                }
            ], 
            "ipv6": [
                {
                    "address": "::1%1/0"
                }
            ], 
            "macaddress": "unknown", 
            "mtu": "16896", 
            "type": "unknown"
        }, 
        "ansible_lpar_info": "1 test1", 
        "ansible_machine": "00CE5FA34C00", 
        "ansible_memfree_mb": 9992, 
        "ansible_memtotal_mb": 98304, 
        "ansible_nodename": "test1", 
        "ansible_os_family": "AIX", 
        "ansible_pkg_mgr": "svr4pkg", 
        "ansible_processor": "PowerPC_POWER5", 
        "ansible_processor_cores": 2, 
        "ansible_processor_count": 12, 
        "ansible_product_name": "IBM,9119-595", 
        "ansible_product_serial": "02E5FA3", 
        "ansible_python": {
            "executable": "/usr/bin/python", 
            "has_sslcontext": false, 
            "type": "CPython", 
            "version": {
                "major": 2, 
                "micro": 5, 
                "minor": 7, 
                "releaselevel": "final", 
                "serial": 0
            }, 
            "version_info": [
                2, 
                7, 
                5, 
                "final", 
                0
            ]
        }, 
        "ansible_python_version": "2.7.5", 
        "ansible_selinux": false, 
        "ansible_service_mgr": "src", 
        "ansible_ssh_host_key_dsa_public": "AAAAE23Nzav1hVVTNNoYvp7eokKbwY", 
        "ansible_ssh_host_key_ecdsa_public": "AAAAE2VjZHNhLXNoYvp7eokKbwY=", 
        "ansible_ssh_host_key_rsa_public": "AAAAB3Nzav1hVVTNfKiM4W1j9mcw==", 
        "ansible_swapfree_mb": 16558, 
        "ansible_swaptotal_mb": 16896, 
        "ansible_system": "AIX", 
        "ansible_user_dir": "/home/yd_hzj", 
        "ansible_user_gecos": "", 
        "ansible_user_gid": 7, 
        "ansible_user_id": "yd_hzj", 
        "ansible_user_shell": "/usr/bin/ksh", 
        "ansible_user_uid": 263, 
        "ansible_userspace_bits": "32", 
        "ansible_vgs": {
            "realsyncvg": [
                {
                    "free_pps": "6", 
                    "pp_size": "128 megabyte(s)", 
                    "pv_name": "hdisk74", 
                    "pv_state": "active", 
                    "total_pps": "1999"
                }
            ], 
            "rootvg": [
                {
                    "free_pps": "0", 
                    "pp_size": "256 megabyte(s)", 
                    "pv_name": "hdisk0", 
                    "pv_state": "active", 
                    "total_pps": "546"
                }, 
                {
                    "free_pps": "113", 
                    "pp_size": "256 megabyte(s)", 
                    "pv_name": "hdisk1", 
                    "pv_state": "active", 
                    "total_pps": "546"
                }
            ], 
            "testvg": [
                {
                    "free_pps": "838", 
                    "pp_size": "256 megabyte(s)", 
                    "pv_name": "hdisk105", 
                    "pv_state": "active", 
                    "total_pps": "999"
                }, 
                {
                    "free_pps": "599", 
                    "pp_size": "256 megabyte(s)", 
                    "pv_name": "hdisk106", 
                    "pv_state": "active", 
                    "total_pps": "999"
                }
            ]
        }, 
        "module_setup": true
    }, 
    "changed": false
}

* Update facts.py

* Update facts.py
8 years ago
Michael Scherer 968101f611 Fix #17624 (#17627)
Even if the size of the network is 0, it should have a netmask.
8 years ago
Nathaniel Case 881da2b3f1 Fix call to `axapi_call_v3()` (#17637)
Closes #17584
8 years ago
René Moser 6247e7bc38 cloudstack: move common code to module_utils (#17635) 8 years ago
René Moser 3f6f4617dc cloudstack: fix has_changed dict values comparsion (#17632)
In some rare situations, the CloudStack API returns string for numbers
when we expected int.

With this fix, we ensure we compare the types expected.
8 years ago
Peter Sprygada ff52e01a11 Merge pull request #17625 from skg-net/dellos6_template
Added support for template module for Dell Networking OS6 devices
8 years ago
Peter Sprygada 8f8eb84ebf Merge pull request #17613 from Qalthos/pyez_check
Add simple checks for libraries to junos
8 years ago
Peter Sprygada 79d1b51dfb Merge pull request #17623 from dgjustice/nxos_fixes
Fixed transport issues when calling self.execute from Cli
8 years ago
Joshua Elsasser fa5f8a7543 Fix slaac filter (#17551) 8 years ago
d3justi 261666a01b Removed checks from Nxapi class. D\'oh\! 8 years ago
d3justi 07f3b27351 added a couple more checks 8 years ago
Senthil Kumar Ganesan 463349c0d1 Added support template module for Dell Networking OS6 devices 8 years ago
d3justi d34f7c24d9 Fixed transport issues when calling self.execute from Cli 8 years ago
James Cammarata 5a57c66e3c Moving result reading to a background thread 8 years ago
Toshio Kuratomi 2989527cd9 Fix dataloader using deprecated version of is_encrypted (#17615) 8 years ago
Peter Sprygada 6826ed3879 Merge pull request #17622 from privateip/network-plugin-fix
fixes AttributeError: 'Task' object has no attribute '_block'
8 years ago
Peter Sprygada 353f6be273 Merge pull request #17545 from privateip/asa
removes filter attribute from asa
8 years ago
Peter Sprygada 2a7c87a3b7 fixes AttributeError: 'Task' object has no attribute '_block'
This addresses a problem when *_config or *_template network modules are
being used in roles.  The module will error with the above message.  This
fixes that problem

fixed ansible/ansible-modules-core#4840
8 years ago
Matt Clay 07a76bece1 Update submodule refs. 8 years ago
Toshio Kuratomi ce4c0fd644 Use text strings when using display() to avoid UnicodeError tracebacks 8 years ago
Senthil Kumar Ganesan bb9ed50441 Renamed the Modules from dnos* -> dellos*, updated copyright, removed… (#17617)
* Renamed the Modules from dnos* -> dellos*, updated copyright, removed dnos6_template

* Addressed @gundalow comments
8 years ago
ftigeot 9df8a2565f Fix distribution fact on DragonFly (#17619)
* By default, ansible_distribution is not set on DragonFly systems,
  preventing some distribution-specific tests from being written

* This commit fixes the issue by returning the quite logical value
  of "DragonFly" when appropriate
8 years ago
nvigot 10f840e80d include_vars now properly deals with hash_behaviour (#15895) 8 years ago
Adrian Likins 3e754086b6 Fix error using jsonfile with incomplete config (#17567)
If 'fact_caching=jsonfile' was configured, but
'fact_caching_connection' was not configured, jsonfile
would fail and ansible-playbook would exit with a traceback.

Fixes #17566
8 years ago
jctanner 29fda4be1e copy action plugin: recurse into sub folders of the source (#17614)
* copy action plugin: recurse into sub folders of the source

Fixes #13013

* Fix python3 bytes/strings

* Fix py3 again

* test
8 years ago
Brian Coca 4e60f23198 remove bare variable support from loops (#17519)
* remove bare variable support from loops

* Added new 'removed deprecated' section to changelg

also added removed items from this PR and others
8 years ago
Toshio Kuratomi d9c0773609 Update submodule refs 8 years ago
Nathaniel Case b753e8dc48 Add simple checks for libraries to junos 8 years ago
Andrea Tartaglia e0a77bb8d5 Pass the absolute path to dirname when assigning basedir (#17457)
* Pass the absolute path to dirname when assigning basedir

If no path is specified when calling the playbook, os.path.dirname(playbook_path) returns ''
This will cause failure when creating the retry file.

Fixes #17456

* Updated to use os.pathdirname(os.path.abspath())
8 years ago
Peter Sprygada 697888965e Merge pull request #17603 from skg-net/dnos10_facts
Added support for facts module for Dell Networking OS10 device.
8 years ago
Toshio Kuratomi 8af8eec789 Merge pull request #17590 from abadger/vault-fixes
Vault fixes
8 years ago
Senthil Kumar Ganesan 769fa1c2d7 Support for dnos10_facts module 8 years ago
Toshio Kuratomi e70066a6f7 Many Cleanups to vault
* Make is_encrypted_file handle both files opened in text and binary mode
  On python3, by default files are opened in text mode.  Since we know
  the encoding of vault files (and especially the header which is the
  first set of bytes) we can decide whether the file is an encrypted
  vault file in either case.
* Fix is_encrypted_file not resetting the file position
* Update is_encrypted_file to check that all the data in the file is ascii
* For is_encrypted_file(), add start_pos and count parameters
  This allows callers to specify reading vaulttext from the middle of
  a file if necessary.
* Combine VaultLib.encrypt() and VaultLib.encrypt_bytestring()
* Change vault's is_encrypted() to take either text or byte strings and to return False if any part of the data is non-ascii.
* Remove unnecessary use of six.b
* Vault Cipher: mark a few methods as private.
* VaultAES256._is_equal throws a TypeError if given non byte strings
* Make VaultAES256 methods that don't need self staticmethods and classmethods
* Mark VaultAES and is_encrypted as deprecated
* Get rid of VaultFile (unused and feature implemented in a different way)
* Normalize variable and parameter names on plaintext, ciphertext, vaulttext
* Normalize variable and parameter names on "b_" prefix when dealing with bytes
* Test changes:
  * Remove redundant tests( both checking the same byte string)
  * Fix use of format string without format operator
  * Enable vault editor tests on python3
  * Initialize the vault_cipher for VaultAES256 testing in setUp()
  * Make assertTrue and assertFalse take the actual method calls for
    better error messages.
  * Test that non-ascii byte strings compare correctly.
  * Test that unicode strings and ints raise TypeError

* Test-specific:
  * Removed test_methods_exist().  We only have one VaultLib so the
    implementation is the assurance that the methods exist. (Can use an abc for
    this if it changes).
  * Add tests for both byte string and text string input where the API takes either.
  * Convert "assert" to unittest assert functions or add a custom message where
    that will make failures easier to debug.
  * Move instantiating the VaultLib into setUp().
8 years ago
James Cammarata dfb1c0647e Revert "Move queuing tasks to a background thread"
This reverts commit b71957d6e6.
8 years ago
jctanner b93de25204 During initial argument evaluation, cast args to string. (#17595)
Later in the stack, further code will check and inform the user that var names must start with a letter
or underscore, so this fix only allows us to get to that previously existing policy.

Fixes #16008
8 years ago
Adrian Likins 2c54a8471f Improve inventory script error messages. (#17589)
When an inventory file looks executable (with a #!) but
isn't, the error message could be confusing. Especially
if the inventory file was named something like 'inventory'
or 'hosts'. Add some context and quote the filename.

This is based on https://github.com/ansible/ansible/pull/15758
8 years ago
Matt Davis f497d771c8 win_shell/win_command changes + tests (#17557) 8 years ago
Senthil Kumar Ganesan 81072fcba1 Added support OS9 facts (#17591) 8 years ago
Toshio Kuratomi ebc4d577de Update submodule refs 8 years ago
Brian Coca cb071e043c updated subrefs 8 years ago
Monty Taylor cd6e01349e Ensure parent tempdir's existence (#17585)
While doing evil things with action plugins, I hit a code path in which
the mkdir here was failing due to lack of parent dir. Changing this to
makedirs made everything happy. Now, I'd obviously like to understand
why the parent dir exists in some places and not others - but I could
not find anywhere that C.DEFAULT_LOCAL_TMP is ensured to be created.
8 years ago
Toshio Kuratomi 70e63ddf6c Fix cow mode to work with unicode task and play names (#17576)
Fixes #17560
8 years ago
Matt Clay 6787fc70a6 Update submodule refs. 8 years ago
Senthil Kumar Ganesan 68f1705d18 Add action plugin for dnos6_config module (#17553) 8 years ago
Senthil Kumar Ganesan 7d9b07382b Add action pluging for dnos9_template module (#17549) 8 years ago
Senthil Kumar Ganesan 564e02c3c3 Add action plugin for dnos6_template module (#17554) 8 years ago
Senthil Kumar Ganesan daba7fa057 Moved the dnos10_template.py action plugin to the correct directory (#17550) 8 years ago
Toshio Kuratomi f4cd1c6321 Fix galaxy's parsing of the command line. (#17569)
Also make the parsing of the action in both galaxy and vault more
robust.

Fixes #17534
May Fix #17563
8 years ago
Adrian Likins 8438da2a34 Make jsonfile cache plugin errors less vague. (#17568) 8 years ago
Adrian Likins c633022fca [wip] Let jsonfile and memcached cache plugins understand fact_caching_timeout=0 (#17565)
* Add support for no-expiration to jsonfile cache

* Let memcached cache use fact_caching_timeout=0

If fact_cache=memcached and fact_caching_timeout=0
memcached would hit a NameError on _expire_keys
8 years ago
Ryan S. Brown 0bda419f66 Allow AWSRetry class to be created without boto3/botocore installed 8 years ago
Brian Coca 4656b6a846 added msg info to unreachable for oneline callback
fixes #17367
8 years ago
Adam Reznechek 23930d799f Fix cpu facts for hosts missing fields in cpuinfo (16533) (#16535)
Change linux fact gathering to correctly gather ansible_processor_count
and ansible_processor_vcpus on systems without vendor_id/model_name in
/proc/cpuinfo (for ex, ppc64/POWER)
8 years ago
Allen Sanabria b510abce17 CloudRetry/AWSRetry backoff decorator with unit tests (#17039)
* Added aws_retry decorator function with unit tests

* Restructured the code to be used with a base class.

This base class CloudRetry can be reused by any other cloud provider.
This decorator should be used in situations, where you need to implement
a backoff algorithm and want to retry based on the status code from the
exception.

* updated documentation

* fixed tabs

* added botocore and boto3 to requirements.txt

* removed cloud.py from py24 tests, as it depends on boto3

* fix relative imports

* updated test to be 2.6 compat

* updated method name from retry to backoff

* readded lxd

* Updated default backoff from 2 seconds to 1.1s.

This will be about a total of 48 seconds in 10 tries. This is
configurable.
8 years ago
Brian Coca 60706cc12e doas update (#16997)
hopefully fixes #15597
8 years ago
Peter Sprygada 760fff8564 Merge pull request #17546 from skg-net/dnos9_config
Added support for dnos9_config module
8 years ago
Brian Coca db8c952ee3 added new ksu method to man page
removed runas refrences, because it was never implemented
8 years ago
Nathaniel Case 5331dd482c Cleanup eos (#17548) 8 years ago
Senthil Kumar Ganesan c6acf44a7c Added support for dnos9_config module 8 years ago
Nathaniel Case 8b3ae1e806 Cleanup netcfg.py (#17531)
Closes #17412
8 years ago
Peter Sprygada c9d74e9a6e removes filter attribute from asa
This removes the filter attribute from the asa shared module and moves
the function to the asa_acl module where it was used.
8 years ago
Brian Coca 7450629733 better display for free strategy (#17355) 8 years ago
John R Barker e326da28ff eos: cmd should be item (#17540)
Was changed during
7fe64ef9b8
however not all look variables were updated.
8 years ago
Abhijit Menon-Sen 07756a4265 Remove extraneous . from VALID_FILE_EXTENSIONS
Otherwise if you «include_vars: vars.json», you get this error:

    "message": "/path/to/vars.json does not have a valid extension: yaml, yml, .json"
8 years ago
Toshio Kuratomi b0d81a43d7 Update submodule refs 8 years ago
Brian Coca 8ebd8ca259 updated solaris virtualization detection (#17464)
avoid prtdiag since it seems to hang and require service restarts
hopefully fixes #4583
8 years ago
Nathaniel Case 036650cb09 Cleanup junos (#17530)
Closes #17411
8 years ago
Peter Sprygada 076a821821 Merge pull request #17468 from skg-net/dnos9_command
dnos9_command (new module)
8 years ago
Nathaniel Case bfe341177b Cleanup netcli (#17529)
This honestly mostly amounts to Python 3 fixes.
8 years ago
Toshio Kuratomi bf29961947 Fixes to the controller text model (#17527)
* Fixes to the controller text model

* Change command line args to text type
* Make display replace undecodable bytes with replacement chars.  This
  is only a problem on pyhton3 where surrogates can enter into the msg
  but sys.stdout doesn't know how to handle them.
* Remove a deprecated playbook syntax in unicode.yml

* Fix up run_cmd to change its parameters to byte string at appropriate times.
8 years ago
Toshio Kuratomi 9868117d1f Update submodule ref for core to fix broken service module 8 years ago
Toshio Kuratomi 499b13d649 Update submodule refs 8 years ago
Senthil Kumar Ganesan 1c7c3cc878 Addressed review comments from @gundalow 8 years ago
Senthil Kumar Ganesan 3e18676af4 Addded support for dnos9_command module 8 years ago
Nathaniel Case 060ed665f6 Cleanup nxos
closes #17414
8 years ago
Peter Sprygada 5aa83041bf Merge pull request #17474 from skg-net/dnos6_command
Add module_utils/dnos6.py
8 years ago
Peter Sprygada cc45506006 Merge pull request #17521 from privateip/fix-4797
raise exception when src file is not found in net_config
8 years ago
Nathaniel Case fcd4be28ee Cleanup openswitch
Also bump get_config in vyos, to pick up the addition of **kwargs

Closes #17415
8 years ago
Senthil Kumar Ganesan 05e016e4aa Addressed @gundalow review comments 8 years ago
Senthil Kumar Ganesan 94df740ca3 Added support for dnos6_command module 8 years ago
Toshio Kuratomi 6117e1946e Check controlpersist (#17443)
* Add a new config option to cache the check for controlpersist on the
control machine.

Fixes #15844

* Remove the option and make the behavior the default

* Make the check for controlpersist cache its status per-ssh executable
8 years ago
Nathaniel Case 2077e32ddd Vyos cleanup
Addresses #17416
8 years ago
Peter Sprygada 16d6274276 raise exception when src file is not found in net_config
This will now raise an exception if the file path specified in src is not
found and the module will gracefully error.

ref #4797
8 years ago
Peter Sprygada 4e325274d6 Merge pull request #17512 from privateip/nxos
roll up of updates to nxos shared module
8 years ago
Peter Sprygada 7777c38b95 Merge pull request #17508 from privateip/sros
updates sros shared module
8 years ago
Peter Sprygada e83567a8ec Merge pull request #17509 from privateip/vyos
roll up of updates to vyos shared module
8 years ago
Peter Sprygada 560984d282 Merge pull request #17511 from privateip/junos
updates junos shared module methods
8 years ago
Peter Sprygada 7c4dad4275 Merge pull request #17513 from privateip/eos
cleans up load_config() in eos shared module
8 years ago
Peter Sprygada ebe2400af8 Merge pull request #17510 from privateip/iosxr
clean up iosxr shared module
8 years ago
John R Barker 8a3b520f70 Add missing space in loop variable reuse message (#17516) 8 years ago
Peter Sprygada f4af154bef Merge pull request #17506 from privateip/openswitch
minor clean of openswitch shared module
8 years ago
Peter Sprygada db744e1233 Merge pull request #17507 from privateip/netcfg
removes unneeded message in netcfg
8 years ago
nitzmahone 8d1f96dd82 bump core submodule ref for win_user fixes 8 years ago
Peter Sprygada d2e4ddf0b0 roll up of updates to nxos shared module
* combine same functions into NxapiConfigMixin class
* update Cli and Nxapi to use mixin
8 years ago
Peter Sprygada e9f804614d removes unneeded message in netcfg
removes old warning message in netcfg that is no longer used
8 years ago
Peter Sprygada 815a683e9c minor clean of openswitch shared module
* updates regexp entries
* removes legacy 2.1 code for get_module()
8 years ago
Peter Sprygada 75f1573ed5 roll up of updates to vyos shared module
* cleans up method signature
* removes save_config method in favor of super class
8 years ago
Peter Sprygada a6cf394ebc updates sros shared module
* adds rollback to load_config() method
* updates error regexp list
8 years ago
Peter Sprygada e5d931de6b updates junos shared module methods
* cleans up load_config() arguments to simply
* removes unused methods in Cli transport
* updates error regexp
8 years ago
Peter Sprygada a8daff1590 clean up iosxr shared module
fixes up method signatures in iosxr shared module removing unneeded **kwargs
8 years ago
Peter Sprygada 456fbf011e cleans up load_config() in eos shared module
cleans up the load_config() method
8 years ago
James Cammarata f5cff2ced5 Revert "Flush the queued items in linear periodically"
This reverts commit d3418fd658.
8 years ago
Robin Schneider d76dd56ca3
Use addresses and names reserved for documentation
Trying to preserve the meaning of the examples. Not all occurrences in
`docsite/rst/playbooks_lookups.rst` have been changed for instance to
allow the unchanged examples to be used for testing.

Related to: #17479
8 years ago
James Cammarata d3418fd658 Flush the queued items in linear periodically 8 years ago
James Cammarata 6b206f5d00 Re-adding processing of results inline with queuing tasks for linear 8 years ago
Chris Houseknecht 39aa740531
Use LooseVersion comparison. Default docker_api_version to 'auto'. 8 years ago
Peter Oliver c87d84f5b8 Filesystem blocks are of size `f_frsize` (#17493)
The statvfs(3) manpage on Linux states that `f_blocks` is the "size of fs in `f_frsize` units".  The manpages on Solaris and AIX state something similar.

With ext4 on Linux, I suspect that `f_bsize` and `f_frsize` are always identical, masking this error.  On Solaris, the sizes differ for each of ufs, vxfs and zfs causing the `size_available` and `size_total` facts to be set incorrectly on this OS.
8 years ago
Brian Coca a3028783d4 removed previously deprecated ';' host separator 8 years ago
Brian Coca 0aaee0272a using delegated host's facts when delegating (#17489)
fixes #17313
8 years ago
jctanner af2ce7725b Iterate through role paths when installing roles (#17487)
* Iterate through role paths when attempting to install roles
8 years ago
Alvaro Aleman e8897a9b91 Fix from_yaml for non-string_types. This resolves #17397 (#17398) 8 years ago
Peter Sprygada 19e00cf160 Merge pull request #17481 from privateip/junos
minor update to catch expection if trying close a non existent session
8 years ago
Brian Coca cd2f60e11a take delegated vars before removing them
fixes #17455
8 years ago
Dag Wieers 2daf527e63 Fix fileglob filter to work just like fileglob lookup plugin (#17480)
The fileglob lookup plugin only returns files, not directories.
This is to be expected, as a mixed list would not be very useful in with_fileglob.
However the fileglob filter does return anything glob.glob() returns.

This change fixes this, so that fileglob returns files (as the name indicates).

PS We could also offer a glob filter for thos that would need it ?

This relates to comments in issue #17136 and fixes confusion in #17269.
8 years ago
Peter Sprygada 1dac6edbe4 minor update to catch expection if trying close a non existent session
This will prevent the junos shared module from throwing an exception if
the session is trying to be closed when it doesn't exist
8 years ago
Dag Wieers d52a9cee46 Support late evaluation, suppress warnings on SyntaxError (#17462)
See #14304 comments (https://github.com/ansible/ansible/pull/14304#issuecomment-245453209) for more information.
8 years ago
Matt Martz eefe359d6b Don't use the shell to catch output, catch output in python. Fixes #17137 (#17449) 8 years ago
Dag Wieers 1df924e1d5 Clean up unarchive action plugin (#17429) 8 years ago