CDIST-TYPE__ACL(7)
β¨ cdist-type__acl π β the set ACL entries era
okay bestie so this is cdist-type__acl, part of the cdist manual (section 7), and it's literally the type that sets your ACL entries. file permission drama? solved. periodt. π
πΈ DESCRIPTION
Fully supported and tested on Linux (ext4 filesystem) π§, with partial support for FreeBSD. so like, Linux is the main character here, FreeBSD is lowkey invited but not fully in the group chat, ngl.
For the full tea, go peek at the setfacl and acl manpages β they have all the extra lore.
β οΈ You must use one of--entryor--source. Not optional, not a vibe, it's a requirement. no cap.
π§ OPTIONAL MULTIPLE PARAMETERS
entryβ sets an ACL entry following thegetfacloutput syntax. You must use this one if--sourceisn't being used. it's giving "pick me, I'm the one you need" π
π¦ OPTIONAL PARAMETERS
sourceβ reads ACL entries from stdin or from a file. the ordering of entries does not matter, so don't stress about lining them up like a perfectly curated playlist π§. When reading from a file, comments and empty lines are ignored (they simply don't exist to this type, iconic behavior). You must use this if--entryisn't being used.fileβ create/change a file with__fileusing theuser:group:modepattern. yes the whole pattern, exactly like that πdirectoryβ create/change a directory with__directoryusing theuser:group:modepattern. same energy, but for a dir π
π BOOLEAN PARAMETERS
defaultβ sets all ACL entries as default too. Heads up bestie: only directories can have default ACLs, and setting a default ACL in FreeBSD is currently not supported. so if you're on FreeBSD and try this, it's a no from the codebase πrecursiveβ makessetfaclrecursive (Linux only!!), but notgetfaclin explorer. so like, it goes down the tree for setting, but the explorer isn't doing the same. iykyk.removeβ removes undefined ACL entries. π§Ή but real talk:maskandotherentries can't be removed, they can only be changed. so don't come for them, they're not going anywhere. π
π₯ EXAMPLES
the moment you've been waiting for, the main event, the slay:
__acl /srv/project \
--default \
--recursive \
--remove \
--entry user:alice:rwx \
--entry user:bob:r-x \
--entry group:project-group:rwx \
--entry group:some-other-group:r-x \
--entry mask::r-x \
--entry other::r-x
then we've got the sneaky one β giving Alice read-only access to a subdir, but not letting her see the parent content:
# give Alice read-only access to subdir,
# but don't allow her to see parent content.
__acl /srv/project2 \
--remove \
--entry default:group:secret-project:rwx \
--entry group:secret-project:rwx \
--entry user:alice:--x
__acl /srv/project2/subdir \
--default \
--remove \
--entry group:secret-project:rwx \
--entry user:alice:r-x
reading an ACL from stdin, because piping is self-care π«Ά:
# read acl from stdin
echo 'user:alice:rwx' \
| __acl /path/to/directory --source -
and finally, creating/changing the directory too, because why not do both:
# create/change directory too
__acl /path/to/directory \
--default \
--remove \
--directory root:root:770 \
--entry user:nobody:rwx
π AUTHORS
Ander Punnar <ander-at-kvlt-dot-ee> β absolute legend, wrote the whole thing π
π COPYING
Copyright (C) 2018 Ander Punnar. You can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
(yes that's the standard GPL blessing, we love a permissive queen π)
β COPYRIGHT
ungleich GmbH 2021
and that's the whole page bestie, tysm for reading, ily π«Ά β this was cdist-type__acl from the cdist manual, version 7.0.0, dated Jul 31, 2022. go forth and set your ACLs correctly, no cap. π
β¨
π¦ where this page comes from
- fedora 43: cdist 7.0.0-16.fc43 Β· GPL-3.0-only
- fedora 44: cdist 7.0.0-18.fc44 Β· GPL-3.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms