Add the ability to set owner to the path
This commit is contained in:
parent
9ab465e022
commit
ec14e608d0
@ -100,9 +100,10 @@ A complete overview of share options follows below. Only `name` is required, the
|
|||||||
| Option | Default | Comment |
|
| Option | Default | Comment |
|
||||||
| :--- | :--- | :--- |
|
| :--- | :--- | :--- |
|
||||||
| `name` | - | The name of the share. |
|
| `name` | - | The name of the share. |
|
||||||
| `path` | /{{samba_shares_root}}/{{name}} | The path to the share directory. |
|
| `path` | /{{samba_shares_root}}/{{name}} | The path to the share directory. |
|
||||||
| `comment` | - | A comment string for the share |
|
| `comment` | - | A comment string for the share |
|
||||||
| `public` | `no` | Controls read access for guest users |
|
| `public` | `no` | Controls read access for guest users |
|
||||||
|
| `path_owner` | `root` | Set the owner of the path |
|
||||||
| `valid_users` | - | Controls read access for registered users. Use the syntax of the corresponding Samba setting. |
|
| `valid_users` | - | Controls read access for registered users. Use the syntax of the corresponding Samba setting. |
|
||||||
| `write_list` | - | Controls write access for registered users. Use the syntax of the corresponding Samba setting. |
|
| `write_list` | - | Controls write access for registered users. Use the syntax of the corresponding Samba setting. |
|
||||||
| `group` | `users` | The user group files in the share will be added to. |
|
| `group` | `users` | The user group files in the share will be added to. |
|
||||||
|
@ -43,7 +43,7 @@
|
|||||||
file:
|
file:
|
||||||
state: directory
|
state: directory
|
||||||
path: "{{ item.path|default([samba_shares_root,item.name]|join('/')) }}"
|
path: "{{ item.path|default([samba_shares_root,item.name]|join('/')) }}"
|
||||||
owner: root
|
owner: "{{ item.path_owner|default('root') }}"
|
||||||
group: "{{ item.group|default('users') }}"
|
group: "{{ item.group|default('users') }}"
|
||||||
mode: "{{ item.directory_mode|default('0775') }}"
|
mode: "{{ item.directory_mode|default('0775') }}"
|
||||||
setype: "{{ item.setype|default('samba_share_t') }}"
|
setype: "{{ item.setype|default('samba_share_t') }}"
|
||||||
|
Loading…
Reference in New Issue
Block a user