mirror of
https://github.com/dockur/windows.git
synced 2025-10-27 19:35:49 +00:00
Update samba.sh
This commit is contained in:
parent
5d9e0291cb
commit
9dd3edb127
1 changed files with 35 additions and 0 deletions
35
src/samba.sh
35
src/samba.sh
|
|
@ -1 +1,36 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
set -Eeuo pipefail
|
||||||
|
|
||||||
|
[[ "$DHCP" == [Yy1]* ]] && return 0
|
||||||
|
|
||||||
|
{ echo "[global]"
|
||||||
|
echo " netbios name = dockur"
|
||||||
|
echo " workgroup = WORKGROUP"
|
||||||
|
echo " server string = Dockur"
|
||||||
|
echo " interfaces = dockerbridge"
|
||||||
|
echo " bind interfaces only = yes"
|
||||||
|
echo " security = user"
|
||||||
|
echo " guest account = nobody"
|
||||||
|
echo " map to guest = Bad User"
|
||||||
|
echo " server min protocol = SMB2"
|
||||||
|
echo ""
|
||||||
|
echo " # disable printing services"
|
||||||
|
echo " load printers = no"
|
||||||
|
echo " printing = bsd"
|
||||||
|
echo " printcap name = /dev/null"
|
||||||
|
echo " disable spoolss = yes"
|
||||||
|
echo ""
|
||||||
|
echo "[data]"
|
||||||
|
echo " path = /storage"
|
||||||
|
echo " comment = Storage"
|
||||||
|
echo " writable = yes"
|
||||||
|
echo " guest ok = yes"
|
||||||
|
echo " guest only = yes"
|
||||||
|
echo " create mode = 0777"
|
||||||
|
echo " directory mode = 0777"
|
||||||
|
} > "/etc/samba/smb.conf"
|
||||||
|
|
||||||
|
smbd -D
|
||||||
|
wsdd -i dockerbridge -n Host -p
|
||||||
|
|
||||||
|
return 0
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue