Commit Graph

1280 Commits (8f0d8a854635f378c51dffe79ae70a7f672f808f)

Author SHA1 Message Date
Daniel Hokka Zakrisson 1601f0b4d7 Use repr to transfer JSON-arguments, so Python doesn't eat things
Fixes transferring newlines in args:, as well as """.
13 years ago
Daniel Hokka Zakrisson bcf7a2c53a Catch all exceptions coming from lookup plugins
Fixes using $TEMPLATE() and hostvars in a task without a name, among
other things.
13 years ago
Michael DeHaan 1366c663eb Merge branch 'copy-diff-take2' of git://github.com/stoned/ansible into better_diff
Conflicts:
	library/file
13 years ago
Daniel Hokka Zakrisson 93f02d614b Merge pull request #2187 from dhozac/argument-type-check
Add type checking for module arguments, converting as much as possible
13 years ago
Stoned Elipot 8816dc7ca7 Make diff header lines more explicit about what the diff is about
This gives a more readable output when producing diff for a task
with multiple items (with_items).
13 years ago
Stoned Elipot 1b8c9bab35 Fix diff when template destination is absent 13 years ago
Daniel Hokka Zakrisson 22e40b6a61 Merge pull request #2198 from skvidal/nolog-params
No_log params
13 years ago
Stoned Elipot 10e9f1fc1e Implement --diff for the copy module. 13 years ago
Seth Vidal f02ea15f0c command: make sure that all _handle_aliases() calls returns {}
module_common: also work if there are no aliases (shell, command, etc) modules
13 years ago
Seth Vidal c95848ae59 - add an aliases attribute as a lookup of aliasname to canonical name
of parameters
- add support for no_log attribute per-parameter which will not log
  that information to syslog
13 years ago
Daniel Hokka Zakrisson e32fbd312f Shell-quote environment contents 13 years ago
Daniel Hokka Zakrisson 27f3ba53f9 Remove debug print for environment 13 years ago
Daniel Hokka Zakrisson 1df56c07d3 If expand_lists is true, make lookup plugin result into a string
Fixes #2196.
13 years ago
Daniel Hokka Zakrisson 7e0ee6809c Don't template delegate_to too early, not all vars are available
Fixes using delegate_to: $item within a playbook include.
13 years ago
Daniel Hokka Zakrisson f03e845920 Allow hyphens in complex variables
Primarily to support ${hostvars.hostname-with-hyphens.<var>}.
13 years ago
Shaun Zinck e7719e4e46 pass in int() args to get_pty
If LINES or COLUMNS was set, get_pty was failing because it was
expecting an int value to be passed in.
13 years ago
Michael DeHaan 294e43ba2f Removing pipe once since it has some issues about evaluating more than once :) 13 years ago
Daniel Hokka Zakrisson 9076f8eb31 Add type checking for module arguments, converting as much as possible
Converts to list from comma-separated strings, and to dicts from
comma-separated, key=value strings.

Fixes #2126.
13 years ago
Michael DeHaan b75b9681a8 more places to use yaml.safe_load 13 years ago
Michael DeHaan a9ea3136cf Use yaml.safe_load as we are just using basic data structures 13 years ago
Michael DeHaan 5b31feb73b Merge pull request #2179 from skinp/host_connection
Add support for connection type in ansible_hosts file
13 years ago
Patrick Pelletier 2b4ddfb0a2 Handle delegate_to case for local connections in hosts file 13 years ago
Michael DeHaan e51707711c Merge pull request #2120 from jpmens/doc_ex1
Add support for additional EXAMPLES string in Ansible modules
13 years ago
Michael DeHaan f7fb681bb2 Fix comment in chroot connection type 13 years ago
Michael DeHaan 5a1aef5372 Merge branch 'local-chroot-support-v2' of git://github.com/mmoya/ansible into testing 13 years ago
Michael DeHaan 93f73739d3 Merge branch 'paramiko-termcap' of git://github.com/madduck/ansible into testing 13 years ago
Patrick Pelletier 4c0e6722c4 Add support for connection type in ansible_hosts file 13 years ago
Maykel Moya 9a493ef388 Add support for running modules chrooted in a local dir
Adds 'chroot' connection for executing modules chrooted to
a local dir. Requires running ansible as root.

chroot dirs should be specified in the inventory like any
other host.

You can do things like:

$ sudo -E ansible -vvv -f 1 "./chroot1,./chroot2" -c chroot \
  all -m setup
$ sudo -E ansible-playbook -vvv -f 1 -i "./chroot1,./chroot2" \
  -c chroot some-playbook.yml

some-playbook.yml:
---
- hosts: all
  tasks:
    - name: echo something
      shell: echo "Yaaay!" >/tmp/foobar.txt
    - name: install less
      apt: pkg=less state=latest
13 years ago
Stoned Elipot 9f2bba01ba Fix diff output vertical spacing 13 years ago
Michael DeHaan 6d604469d8 Always adjust file attributes with the template module. 13 years ago
Jan-Piet Mens 396a07bcc7 Add support for additional EXAMPLES string in Ansible modules
return DOC and EXAMPLES as a list
add moduledev explanation
more
13 years ago
Michael DeHaan ab389d8908 For consistency, add host should take a key named 'name' in addition to 'hostname'. 13 years ago
Michael DeHaan c4779d95b8 Removing unused import, 'make pyflakes' is now clean. 13 years ago
Michael DeHaan 9cf66f4376 Fixes from 'make pep8'. Partial, more to come. 13 years ago
Michael DeHaan 11e7ede4d9 Merge pull request #2112 from kavink/devel
Fixing syntax error
13 years ago
Michael DeHaan 61d01f549f Show a nicer message when attempting to diff unicode files. 13 years ago
Kavin Kankeshwar 359ac9a495 Fixing syntax error
running install_lib
byte-compiling /usr/lib/python2.6/site-packages/ansible/runner/action_plugins/add_host.py to add_host.pyc
SyntaxError: ('invalid syntax', ('/usr/lib/python2.6/site-packages/ansible/runner/action_plugins/add_host.py', 37, 92, '    def run(self, conn, tmp, module_name, module_args, inject, complex_args=None, **kwargs)\n'))
13 years ago
Daniel Hokka Zakrisson 43d22b0c42 Flatten argument to with_items
Fixes #1711.
13 years ago
Michael DeHaan f02b9987fc We all agreed on the list that the ansible module common module snippet, since it's dynamically embedded in modules on the fly, should
be a BSD licensed snippet so that it's ok to write proprietary modules.  The actual license of Ansible (GPLv3) or any modules
written for ansible (any) do not change.
13 years ago
Michael DeHaan 1ecf4a6943 Working on complex argument support. 13 years ago
Michael DeHaan cd32597af0 Make the file module work as expected in check mode 13 years ago
Michael DeHaan fa21b41357 Fixup the pipe_once plugin 13 years ago
Michael DeHaan 0af83317a1 Added a $PIPE_ONCE lookup plugin, that caches the result so it is only evaluated one time. 13 years ago
Michael DeHaan b365e04616 Allow add_host to add hosts to multiple groups, groups is now an alias for groupname. 13 years ago
Rob Parrott ef17fc9f20 add the ability to take variables in the add_host module, and be willing to parse a host:port hostname handed to add_host 13 years ago
Michael DeHaan c8878998d1 update some of many copyright dates but we can just do this when editing each file, not super high priority 13 years ago
James Martin 7129a9e355 Using "OtherLinux" in module_commons, cleander detection in setup. 13 years ago
James Martin 5646bc278b Support for amazon linux distribution facts. 13 years ago
Michel Blanc 0cd0a7fda3 Fixes jina typos
Moved *jina* to *jinja2*
13 years ago
Michel Blanc 1c22f2146e Adds configurable jinja2 extension loading
Jinja extensions adds features to the jinja2 templating engine. This
patch allows module loading for the templating engine vian an
ansible.cfg configuration key (jinja_extensions).
The default behaviour doesn't change (no module loading).
Requested modules can be added coma separated in ansible.cfg

Adds whitespace handling in jinja_extension config

Added whitespace handling in jinja_extension configuration directive, so
things stay safe if user adds spaces around comas in the directives
list.

Adds config example for jinja_extensions

Added config example with multiple extentions for jinja_extensions
13 years ago