mirror of
https://github.com/bashclub/zamba-lxc-toolbox.git
synced 2024-12-24 11:20:13 +01:00
fix backup, systemd-resolved
This commit is contained in:
parent
fbe274117f
commit
3ce6d7c2ae
@ -193,3 +193,7 @@ elif [[ $service == "zmb-ad-join" ]]; then
|
||||
pct set $LXC_NBR -nameserver "${LXC_IP%/*} $LXC_DNS"
|
||||
fi
|
||||
pct start $LXC_NBR
|
||||
if [[ $service == "zmb-ad" ]] || [[ $service == "zmb-ad-join" ]]; then
|
||||
sleep 5
|
||||
pct exec $LXC_NBR /usr/local/bin/smb-backup 7
|
||||
fi
|
@ -124,7 +124,7 @@ EOF
|
||||
fi
|
||||
|
||||
# stop + disable samba services and remove default config
|
||||
systemctl disable --now smbd nmbd winbind systemd-resolved
|
||||
systemctl disable --now smbd nmbd winbind systemd-resolved > /dev/null 2>&1
|
||||
rm -f /etc/samba/smb.conf
|
||||
rm -f /etc/krb5.conf
|
||||
|
||||
@ -146,10 +146,7 @@ cat << EOF > /usr/local/bin/smb-backup
|
||||
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||
|
||||
rc=0
|
||||
keep=$1
|
||||
if \$1 ; then
|
||||
keep=\$1
|
||||
fi
|
||||
keep=\$1
|
||||
|
||||
mkdir -p /${LXC_SHAREFS_MOUNTPOINT}/{online,offline}
|
||||
|
||||
@ -198,6 +195,4 @@ cat << EOF > /etc/logrotate.d/smb-backup
|
||||
}
|
||||
EOF
|
||||
|
||||
smb-backup 7
|
||||
|
||||
exit 0
|
Loading…
Reference in New Issue
Block a user