2021-03-07 19:40:32 +01:00
|
|
|
{{ file_header | default () }}
|
2021-12-14 20:26:49 +01:00
|
|
|
|
|
|
|
{% if smb_global_options is defined %}
|
2020-08-18 11:57:53 +02:00
|
|
|
#======================= Global Settings =======================
|
2021-12-14 20:26:49 +01:00
|
|
|
{% for item in smb_global_options %}
|
|
|
|
{{ item.option }} = {{ item.value }}
|
|
|
|
{% endfor %}
|
|
|
|
{% endif %}
|
2020-08-18 11:57:53 +02:00
|
|
|
|
2021-12-14 17:05:09 +01:00
|
|
|
{% if smb_enable_snapshots_dir is sameas true and smb_enable_snapshots_shadow is sameas false %}
|
2021-12-14 20:26:49 +01:00
|
|
|
##======================= catia =======================
|
|
|
|
vfs objects = catia
|
|
|
|
catia: mappings = {{ smb_catia_mappings }}
|
2024-02-01 22:20:44 +01:00
|
|
|
{% elif smb_enable_snapshots_dir is sameas false and smb_enable_snapshots_shadow is sameas true %}
|
2021-12-14 20:26:49 +01:00
|
|
|
##======================= shadow_copy2 =======================
|
2024-02-01 22:20:44 +01:00
|
|
|
vfs objects = shadow_copy2
|
2021-12-14 20:26:49 +01:00
|
|
|
shadow: snapdir = {{ smb_shadow_snapdir }}
|
|
|
|
shadow: sort = {{ smb_shadow_sort }}
|
|
|
|
shadow: format = {{ smb_shadow_format }}
|
|
|
|
shadow: snapprefix = {{ smb_shadow_snapprefix }}
|
|
|
|
shadow: delimiter = {{ smb_shadow_delimiter }}
|
|
|
|
shadow: localtime = {{ smb_shadow_localtime }}
|
2024-02-01 22:20:44 +01:00
|
|
|
shadow: snapdirseverywhere = yes
|
2021-12-14 17:05:09 +01:00
|
|
|
{% elif smb_enable_snapshots_shadow is sameas true and smb_enable_snapshots_dir is sameas true %}
|
2021-12-14 20:26:49 +01:00
|
|
|
#======================= vfs objects =======================
|
|
|
|
vfs objects = shadow_copy2, catia
|
|
|
|
##======================= catia =======================
|
2024-02-01 22:12:39 +01:00
|
|
|
catia:mappings = {{ smb_catia_mappings }}
|
2021-12-14 20:26:49 +01:00
|
|
|
##======================= shadow_copy2 =======================
|
|
|
|
shadow: snapdir = {{ smb_shadow_snapdir }}
|
|
|
|
shadow: sort = {{ smb_shadow_sort }}
|
|
|
|
shadow: format = {{ smb_shadow_format }}
|
|
|
|
shadow: snapprefix = {{ smb_shadow_snapprefix }}
|
|
|
|
shadow: delimiter = {{ smb_shadow_delimiter }}
|
|
|
|
shadow: localtime = {{ smb_shadow_localtime }}
|
2024-02-01 22:12:39 +01:00
|
|
|
shadow: snapdirseverywhere = yes
|
2021-12-14 17:05:09 +01:00
|
|
|
{% endif %}
|
2020-08-18 11:57:53 +02:00
|
|
|
|
|
|
|
|
|
|
|
#======================= Share Definitions =======================
|
2021-02-20 15:58:23 +01:00
|
|
|
{% for item in smb_shares %}
|
2020-08-18 11:57:53 +02:00
|
|
|
|
2021-02-20 15:58:23 +01:00
|
|
|
[{{ item.name }}]
|
2021-12-14 20:26:49 +01:00
|
|
|
path = {{ item.path }}
|
|
|
|
guest ok = {{ item.guest_ok | default('no') }}
|
|
|
|
read only = {{ item.read_only | default('no') }}
|
|
|
|
browseable = {{ item.browseable | default('yes') }}
|
|
|
|
inherit acls = {{ item.inherit_acls | default('yes') }}
|
|
|
|
inherit permissions = {{ item.inherit_permissions | default('no') }}
|
|
|
|
ea support = {{ item.ea_support | default('no') }}
|
|
|
|
store dos attributes = {{ item.store_dos_attributes | default('no') }}
|
|
|
|
printable = {{ item.printable | default('no') }}
|
|
|
|
create mask = {{ item.create_mask | default('0664') }}
|
|
|
|
force create mode = {{ item.force_create_mode | default('0664') }}
|
|
|
|
directory mask = {{ item.directory_mask | default('0775') }}
|
|
|
|
force directory mode = {{ item.force_directory_mode | default('0775') }}
|
|
|
|
hide special files = {{ item.hide_special_files | default('yes') }}
|
|
|
|
follow symlinks = {{ item.follow_symlinks | default('yes') }}
|
|
|
|
hide dot files = {{ item.hide_dot_files | default('no') }}
|
|
|
|
valid users = {{ item.users_ro }} {{ item.users_rw }}
|
|
|
|
invalid users =
|
|
|
|
read list = {{ item.users_ro }}
|
|
|
|
write list = {{ item.users_rw }}
|
2020-08-18 11:57:53 +02:00
|
|
|
{% endfor %}
|