mirror of
https://github.com/bashclub/zamba-lxc-toolbox.git
synced 2024-12-25 03:30:12 +01:00
Renamed FILEFS vars to SHAREFS
This commit is contained in:
parent
2a02e79f43
commit
c02558dfe9
@ -72,7 +72,7 @@ select opt in just_lxc zmb-standalone zmb-member zmb-pdc mailpiler matrix quit;
|
|||||||
;;
|
;;
|
||||||
zmb-member)
|
zmb-member)
|
||||||
echo "Configuring LXC container '$opt'!"
|
echo "Configuring LXC container '$opt'!"
|
||||||
pct set $LXC_NBR -mp0 $LXC_FILEFS_STORAGE:$LXC_FILEFS_SIZE,mp=/$LXC_FILEFS_MOUNTPOINT
|
pct set $LXC_NBR -mp0 $LXC_SHAREFS_STORAGE:$LXC_SHAREFS_SIZE,mp=/$LXC_SHAREFS_MOUNTPOINT
|
||||||
sleep 2;
|
sleep 2;
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
|
@ -15,13 +15,13 @@
|
|||||||
LXC_TEMPLATE_STORAGE="local"
|
LXC_TEMPLATE_STORAGE="local"
|
||||||
|
|
||||||
# Define the size and storage location of the container's root filesystem
|
# Define the size and storage location of the container's root filesystem
|
||||||
LXC_ROOTFS_SIZE="100"
|
LXC_ROOTFS_SIZE="32"
|
||||||
LXC_ROOTFS_STORAGE="local-zfs"
|
LXC_ROOTFS_STORAGE="local-zfs"
|
||||||
|
|
||||||
# Define the size, storage location and mountpoint of the container's shared filesystem (required for 'zmb_standalone' and 'zmb_member')
|
# Define the size, storage location and mountpoint of the container's shared filesystem (required for 'zmb_standalone' and 'zmb_member')
|
||||||
LXC_FILEFS_SIZE="100"
|
LXC_SHAREFS_SIZE="100"
|
||||||
LXC_FILEFS_STORAGE="local-zfs"
|
LXC_SHAREFS_STORAGE="local-zfs"
|
||||||
LXC_FILEFS_MOUNTPOINT="tank"
|
LXC_SHAREFS_MOUNTPOINT="tank"
|
||||||
|
|
||||||
# Define whether the container will be created in unprivileged (1) or privileged (0) mode
|
# Define whether the container will be created in unprivileged (1) or privileged (0) mode
|
||||||
# For 'zmb_standalone', 'zmb_pdc', 'zmb_member' and 'mailpiler' the container needs to be created with 'unprivileged=0'
|
# For 'zmb_standalone', 'zmb_pdc', 'zmb_member' and 'mailpiler' the container needs to be created with 'unprivileged=0'
|
||||||
|
@ -78,7 +78,7 @@ cat > /etc/samba/smb.conf <<EOF
|
|||||||
|
|
||||||
[$ZMB_SHARE]
|
[$ZMB_SHARE]
|
||||||
comment = Main Share
|
comment = Main Share
|
||||||
path = /$LXC_FILEFS_MOUNTPOINT/$ZMB_SHARE
|
path = /$LXC_SHAREFS_MOUNTPOINT/$ZMB_SHARE
|
||||||
read only = No
|
read only = No
|
||||||
create mask = 0660
|
create mask = 0660
|
||||||
directory mask = 0770
|
directory mask = 0770
|
||||||
@ -99,13 +99,13 @@ systemctl restart winbind nmbd
|
|||||||
wbinfo -u
|
wbinfo -u
|
||||||
wbinfo -g
|
wbinfo -g
|
||||||
|
|
||||||
mkdir /$LXC_FILEFS_MOUNTPOINT/$ZMB_SHARE
|
mkdir /$LXC_SHAREFS_MOUNTPOINT/$ZMB_SHARE
|
||||||
|
|
||||||
# originally 'domain users' was set, added variable for domain admins group, samba wiki recommends separate group e.g. 'unix admins'
|
# originally 'domain users' was set, added variable for domain admins group, samba wiki recommends separate group e.g. 'unix admins'
|
||||||
chown "$ZMB_ADMIN_USER":"$ZMB_DOMAIN_ADMINS_GROUP" /$LXC_FILEFS_MOUNTPOINT/$ZMB_SHARE
|
chown "$ZMB_ADMIN_USER":"$ZMB_DOMAIN_ADMINS_GROUP" /$LXC_SHAREFS_MOUNTPOINT/$ZMB_SHARE
|
||||||
|
|
||||||
setfacl -Rm u:$ZMB_ADMIN_USER:rwx,g::-,o::- /$LXC_FILEFS_MOUNTPOINT/$ZMB_SHARE
|
setfacl -Rm u:$ZMB_ADMIN_USER:rwx,g::-,o::- /$LXC_SHAREFS_MOUNTPOINT/$ZMB_SHARE
|
||||||
setfacl -Rdm u:$ZMB_ADMIN_USER:rwx,g::-,o::- /$LXC_FILEFS_MOUNTPOINT/$ZMB_SHARE
|
setfacl -Rdm u:$ZMB_ADMIN_USER:rwx,g::-,o::- /$LXC_SHAREFS_MOUNTPOINT/$ZMB_SHARE
|
||||||
|
|
||||||
systemctl restart smbd nmbd winbind
|
systemctl restart smbd nmbd winbind
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user