diff --git a/samba/Dockerfile b/samba/Dockerfile index 4ae5569..cb85654 100644 --- a/samba/Dockerfile +++ b/samba/Dockerfile @@ -16,4 +16,4 @@ EXPOSE 137/udp \ 139/tcp \ 445/tcp -CMD ["smbd", "--foreground", "--log-stdout"] +CMD nmbd -D && smbd -FS diff --git a/samba/README.md b/samba/README.md index e0ef59e..86e1432 100644 --- a/samba/README.md +++ b/samba/README.md @@ -11,14 +11,10 @@ Linux and Unix. ``` samba: image: vimagick/samba - ports: - - "137:137/udp" - - "138:138/udp" - - "139:139/tcp" - - "445:445/tcp" volumes: - ./smb.conf:/etc/samba/smb.conf - ./share:/share + net: host restart: always ``` @@ -56,7 +52,7 @@ Retype new SMB password:****** ## client ``` -$ smbutil view -NG smb://server +$ smbutil view -NG smb://easypi Share Type Comments ------------------------------- share Disk @@ -64,7 +60,7 @@ IPC$ Pipe IPC Service (Samba Serve 2 shares listed $ mkdir -p /Volumes/share -$ mount_smbfs //guest@server/share /Volumes/share +$ mount_smbfs //guest@easypi/share /Volumes/share $ umount /Volumes/share ``` diff --git a/samba/docker-compose.yml b/samba/docker-compose.yml index 5958a1c..6cd13f7 100644 --- a/samba/docker-compose.yml +++ b/samba/docker-compose.yml @@ -1,11 +1,7 @@ samba: image: vimagick/samba - ports: - - "137:137/udp" - - "138:138/udp" - - "139:139/tcp" - - "445:445/tcp" volumes: - ./smb.conf:/etc/samba/smb.conf - ./share:/share + net: host restart: always