Commit Graph

16 Commits (0de2627efc63e0b1f6d24f0bd96d4e5f276ad275)

Author SHA1 Message Date
Jérémie Astori 72fb7a0a17 Fix physical walk on acl module for Linux
`-h` is for BSD [1] while `-P`/`--physical` is for Linux [2].
This commit fixes that option now that acl module is (temporarily)
only supported for Linux.
I will re-add `-h` when fixing BSD support.

[1]: http://www.freebsd.org/cgi/man.cgi?format=html&query=setfacl(1)
[2]: http://linuxcommand.org/man_pages/setfacl1.html
9 years ago
Jérémie Astori 8eefd44aef Make sure entry is not sent when acl state=query 9 years ago
Jérémie Astori 0e659ad872 Make sure permission-less entries are accepted when state=absent
Also, remove that try condition as, at that stage, no permissions with
other than 2 or 3 fields are sent to the function.
9 years ago
Jérémie Astori e95bcaeb8a Remove support for `d[efault]:` in entry permissions
It is not documented in [the Ansible doc page][1] nor
[the BSD setfacl man entry][2] (which means it might not be compatible
with BSD) so removing it does not break the API.

On the other hand, it does not conform with POSIX 1003.1e DRAFT
STANDARD 17 according to the [Linux setfacl man entry][3] so safer to
remove.

Finally, the most important reason: in non POSIX 1003.e mode, only ACL
entries without the permissions field are accepted, so having an
optional field here is very much error-prone.

[1]: http://docs.ansible.com/ansible/acl_module.html
[2]: http://www.freebsd.org/cgi/man.cgi?format=html&query=setfacl(1)
[3]: http://linuxcommand.org/man_pages/setfacl1.html
9 years ago
Jérémie Astori 3ac990556d Fix wrong expectation regarding entry format in acl module 9 years ago
Jérémie Astori 421d3f12cf Fix wrong processing of lines returned by setfacl in test mode 9 years ago
Jérémie Astori 50c6425673 Fix minor whitespace issues 9 years ago
Brian Coca d61fde42ef updated encoding comment and expanded authors field 9 years ago
Jérémie Astori acfc2166b0 Set version number in recursive option description 9 years ago
Jérémie Astori f8027a7f0a Ensure Python 2.4 compatibility and Linux-restricted support
- Make build_entry compatible with Python 2.4
- Re-add missing warning/comment that was forgotten while refactoring
- Replace `all()` with a good ol' for-loop Python 2.4 compatibility
- Make a condition check more explicit (when `state` is `query`)
- Make sure this module can only be run with on a Linux distribution
- Add a note about Linux-only support in the documentation
- Set the version in which recursive support was added, 2.0
9 years ago
Jérémie Astori ae1126c217 Add recursive support for ACL module (fix #5053, fix #5550, fix #7276) 9 years ago
Greg DeKoenigsberg 2a5f0bde87 Proper author info for all remaining modules 9 years ago
Brian Coca 13cdadcc4d removed always for success, as data wont show on fail 10 years ago
Brian Coca cbf42c95b2 draft for documenting module returns 10 years ago
anatoly techtonik 4f2b99c1e0 acl: Fix X support in ACL permissions
If you try to set rwX permissions, ACL fails to set them at all.

Expected:

    $ sudo setfacl -m 'group::rwX' www
    ...
    drwxrwxr-x  2 root root  4096 Nov 10 17:09 www

With Ansible:

    acl: name=/var/www permissions=rwX etype=group state=present
    ...
    drwxrw-r-x  2 root root  4096 Nov 10 17:30 www

x for group is erased. =/
10 years ago
Michael DeHaan c8e1a2077e file extensions! 10 years ago