summaryrefslogtreecommitdiff
path: root/lib/ansible/modules/files
Commit message (Collapse)AuthorAgeFilesLines
* Read directory_mode as 'raw' typeBrendan Almonte2017-05-231-1/+1
| | | | | | | | | Reads the directory_mode param as 'raw' type to mirror the same behavior as mode. This'll cause non-quoted values to be represented as an int, rather than a str. Covered by 'assert recursive copied directories mode' test. Fixes #24202
* Fix logic surrounding copy and remote_src, remote_src is preferred, make ↵Matt Martz2017-05-221-5/+2
| | | | copy action plugin only. Fixes #23591 (#24732)
* Changed assemble_from_fragments to use os.path.join (#24909)pdasilva2017-05-221-1/+1
| | | Fixes #19437
* Downgraded more modules from Curated to Community (#24751)Dylan Silva2017-05-181-1/+1
|
* Fix version_added for new option in template introduced in #21846 (#24307)Matt Martz2017-05-041-6/+6
|
* Make fetch default to fail on errorsToshio Kuratomi2017-05-031-5/+11
| | | | Fixes #23501
* Fix places where path needs to be bytes on python3Toshio Kuratomi2017-05-031-6/+6
| | | | | These were discovered on python3 with fetch code that fails on errors. Probably could be provoked with particular sets of arguments to stat as well.
* synchronize: Fix (delegated) local rsyncErwin Lang2017-04-271-1/+9
| | | | | Makes delegated local rsync work even if ansible_host or ansible_ssh_host is set. Makes local rsync work when no ssh is installed.
* fixed RETURN docs for modules (#24011)Andrea Tartaglia2017-04-263-2/+4
| | | | | | | | * fixed RETURN docs for remaining modules * updated proxymysql_mysql_users 'sample' to yaml dict * fixed whitespace errors
* make lineinfile docs clearer and make module pep8 (#23857)Sloane Hertel2017-04-231-3/+4
|
* ini_file 'create' parameter default value should be TrueMatt Parkes2017-04-131-1/+1
| | | Updated create default value to True to match documentation (and common sense).
* stat: better documentationRitesh Khadgaray2017-04-111-1/+2
| | | | - md5 fails if the file is not a regular file ( symlink, dir,..)
* file module doesn't create hard link to given target directoryHao Wang2017-04-101-2/+12
|
* Open unarchive file in binary modeKarl Bergström2017-04-071-3/+4
| | | | | | | | Recent Python3 versions require open() to specify binary mode if the data is anything other than text. Python3: Use int() instead of long() in unarchive Changes long() to int() for CRC values in the unarchive module. Affects unarchiving of zip files. Since CRC values in zipfile are 32 bits the behaviour should be unchanged even in Python 2.
* Open file in binary mode for python3Paul Montero2017-04-071-3/+5
|
* synchronize: Exclude ssh_args from quotingErwin Lang2017-03-301-2/+2
| | | | Makes it possible again to pass more than one argument via ssh_args to the synchronize module.
* let user control "auto-de-vault" (#22739)Brian Coca2017-03-243-1/+3
| | | | | | * added option to toggle off autodevaulting * fixes per feedbazck
* synchronize: Convert cmd to list and fix handling of the copy_links argument ↵Erwin Lang2017-03-241-59/+63
| | | | | | | | | | (#22573) * synchronize: Convert cmd to list and fix handling of the copy_links argument Converting cmd from str to list stops the pain of argument quoting/escaping. * synchronize: Update imports according to #pullrequestreview-28758614
* Revert "Quote ssh_args"Toshio Kuratomi2017-03-241-16/+5
| | | | This reverts commit a9c3a452f04df12c24294aba7066c10096d1e0d6.
* Quote ssh_argsToshio Kuratomi2017-03-241-5/+16
| | | | Fixes #22111
* Windows: Use the correct newline sequence for the platform (#21846)Dag Wieers2017-03-231-7/+41
| | | | | | | | | | | | | This change to the template action plugin make template use the platform's native newline_sequence for Jinja. We also added the option `newline_sequence` to change the newline sequence using by Jinja if you need to use another newline sequence than the platform default. This was previously discussed in https://github.com/ansible/ansible/issues/16255#issuecomment-278289414 And also relates to issue #21128
* E501 fixes (#22879)Matt Martz2017-03-226-18/+42
|
* ported fix from ansible-core #5639Brian Coca2017-03-211-0/+13
| | | | | From 3d09c94faeaa52075055f23744d8b52581c59bb2 Mon Sep 17 00:00:00 2001 Evan Kaufman <evan@digitalflophouse.com>
* corrected docsBrian Coca2017-03-161-5/+5
|
* Add parameters to limit replace to certain section of the fileJens Carl2017-03-161-2/+68
| | | | | Add parameters 'after' and 'before' to limit the replacement/remove of lines to a certain section of the file.
* New metadata 1.0 (#22587)Toshio Kuratomi2017-03-1419-57/+76
| | | | | | | | | | | | | | | | Changes to the metadata format were approved here: https://github.com/ansible/proposals/issues/54 * Update documentation to the new metadata format * Changes to metadata-tool to account for new metadata * Add GPL license header * Add upgrade subcommand to upgrade metadata version * Change default metadata to the new format * Fix exclusion of non-modules from the metadata report * Fix ansible-doc for new module metadata * Exclude metadata version from ansible-doc output * Fix website docs generation for the new metadata * Update metadata schema in valiate-modules test * Update the metadata in all modules to the new version
* Fix invalid fields in module DOCUMENATION (#22297)John R Barker2017-03-091-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * fix module doc fields * More module docs corrections * More module docs corrections * More module docs corrections * More module docs corrections * correct aliases * Review comments * Must quote ':' * More authors * Use suboptions: * restore type: bool * type should be in the same place * More tidyups * authors * Use suboptions * revert * remove duplicate author * More issues post rebase
* Document synchronize limitations around become and connections (#22373)Toshio Kuratomi2017-03-071-0/+2
| | | * Document synchronize limitations around become and connections
* Show diff when file: state=link changes the symlink target (#22243)Marius Gedminas2017-03-061-0/+2
| | | | | | | | * Show diff when file: state=link changes the symlink target * Integration test for symlink target change * Also check soft link idempotency
* Ensure that filenames from archives are not expandedDag Wieers2017-03-021-2/+2
| | | | This fixes #21795
* Fix #22130 (ini_file crash when destination file don't exists or is e… ↵Benjamin Jolivot2017-03-011-0/+4
| | | | | (#22132) * Fix #22130 (ini_file crash when destination file don't exists or is empty)
* iso_extract: new module to extract files from ISO images (#21957)Dag Wieers2017-03-011-0/+130
| | | | This is the original iso_extract module from the ansible-provisioning project. We are upstreaming all our modules, and this PR is part of that process.
* Removes expanduser callsTim Rupp2017-02-271-1/+1
| | | | | The usage of type='path' includes the expanduser call itself. This patch removes its duplicate usage. Related to #12263
* Remove unnecessary shebangs and execute bits.Matt Clay2017-02-221-0/+0
|
* synchronize: quote private_key (#21570)Evgeni Golov2017-02-171-1/+1
| | | | | otherwise rsync will fail when trying to access a key with spaces: fatal: [default]: FAILED! => {"changed": false, "cmd": "/usr/bin/rsync --delay-updates -F --compress --archive --rsh 'ssh -i /home/user/Some Folder/.vagrant/machines/default/libvirt/private_key -S none -o StrictHostKeyChecking=no -o Port=22' --out-format='<<CHANGED>>%i %n%L' \"/etc/issue\" \"vagrant@192.168.121.10:/tmp/issue2\"", "failed": true, "msg": "Warning: Identity file /home/user/Some not accessible: No such file or directory.\nssh: Could not resolve hostname folder/.vagrant/machines/default/libvirt/private_key: No address associated with hostname\r\nrsync: connection unexpectedly closed (0 bytes received so far) [sender]\nrsync error: unexplained error (code 255) at io.c(226) [sender=3.1.2]\n", "rc": 255}
* Validate EXAMPLES as YAMLMatt Martz2017-02-151-4/+4
|
* archive docs formatting (#21454)John R Barker2017-02-151-3/+2
|
* Removes usage of expanduser due to type 'path'Tim Rupp2017-02-131-1/+1
| | | | | | Removes the usage of the expanduser function because it is being performed automatically by the type 'path' of the path option.
* Adds path type and remove expanduserTim Rupp2017-02-131-4/+4
| | | | | | Related to #12263, this patch removes the usage of expanduser in favor of the path 'type' for the module options of src and dest
* Remove expanduser usage because of path typeTim Rupp2017-02-131-2/+2
| | | | | With the addition of the 'path' type, the usage of expanduser is redundant. This patch removes that extra usage.
* Avoid having module documentation links to itself (#21329)Dag Wieers2017-02-136-7/+7
| | | | | | | | | * Avoid having module documentation links to itself A lot of modules use M(own_module) in their documentation causing a link in the documentation to itself. * Make note more clear now
* Fix incorrect wording in the 'find' module 'paths' parameterTim Bielawa2017-02-101-1/+1
|
* Fix typo in example (#21227)Dag Wieers2017-02-091-2/+2
|
* Fix default value for remote_src (#21136)Tuomas-Matti Soikkeli2017-02-091-1/+1
| | | Default value is clearly False, fixed it to correct value.
* Reminder that lookup(‘file’) can be used (#20649)Craig Francis2017-02-071-0/+6
| | | | | | | | | | | | | | * Reminder that lookup(‘file’) can be used Sometimes the block of text does not easily fit into a playbook, so this acts as a reminder (or a prompt for anyone who hasn't used this before) that the content could be stored in an separate file. I've also included `backup: yes` as I think this is a good example of where a backup might be needed. * Correct the not so "smart quotes" * Update blockinfile.py Replace – with an an ASCII -
* minor fixes to template docsBrian Coca2017-02-061-9/+9
|
* Update validate-modules (#20932)Matt Martz2017-02-023-36/+31
| | | | | | | | | | | | | | * Update validate-modules * Validates ANSIBLE_METADATA * Ensures imports happen after documentation vars * Some pep8 cleanup * Clean up some left over unneeded code * Update modules for new module guidelines and validate-modules checks * Update imports for ec2_vpc_route_table and ec2_vpc_nat_gateway
* PEP 8 E111 & E114 cleanup. (#20838)Matt Clay2017-01-304-19/+19
|
* PEP 8 indent cleanup. (#20800)Matt Clay2017-01-292-2/+2
| | | | | | | | * PEP 8 E121 cleanup. * PEP 8 E126 cleanup. * PEP 8 E122 cleanup.
* Remove duplicate import.Matt Clay2017-01-281-1/+0
|