mirror of
https://github.com/vimagick/dockerfiles
synced 2024-06-28 17:51:24 +00:00
update samba
This commit is contained in:
parent
3c13916822
commit
d6e7cddebd
@ -5,11 +5,15 @@
|
|||||||
FROM alpine
|
FROM alpine
|
||||||
MAINTAINER kev <noreply@datageek.info>
|
MAINTAINER kev <noreply@datageek.info>
|
||||||
|
|
||||||
RUN apk add -U samba-common-tools samba-server \
|
RUN set -xe \
|
||||||
|
&& apk add -U samba-common-tools samba-server \
|
||||||
&& rm -rf /var/cache/apk/*
|
&& rm -rf /var/cache/apk/*
|
||||||
|
|
||||||
COPY smb.conf /etc/samba/
|
COPY smb.conf /etc/samba/
|
||||||
|
|
||||||
EXPOSE 137/udp 138/udp 139/tcp 445/tcp
|
EXPOSE 137/udp \
|
||||||
|
138/udp \
|
||||||
|
139/tcp \
|
||||||
|
445/tcp
|
||||||
|
|
||||||
CMD smbd --foreground --log-stdout
|
CMD ["smbd", "--foreground", "--log-stdout"]
|
||||||
|
@ -3,7 +3,7 @@ samba
|
|||||||
|
|
||||||
![](https://badge.imagelayers.io/vimagick/samba:latest.svg)
|
![](https://badge.imagelayers.io/vimagick/samba:latest.svg)
|
||||||
|
|
||||||
[`Samba`][1] is the standard Windows interoperability suite of programs for
|
[Samba][1] is the standard Windows interoperability suite of programs for
|
||||||
Linux and Unix.
|
Linux and Unix.
|
||||||
|
|
||||||
## docker-compose.yml
|
## docker-compose.yml
|
||||||
@ -17,8 +17,8 @@ samba:
|
|||||||
- "139:139/tcp"
|
- "139:139/tcp"
|
||||||
- "445:445/tcp"
|
- "445:445/tcp"
|
||||||
volumes:
|
volumes:
|
||||||
- smb.conf:/etc/samba/smb.conf
|
- ./smb.conf:/etc/samba/smb.conf
|
||||||
- share:/share
|
- ./share:/share
|
||||||
restart: always
|
restart: always
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -28,11 +28,12 @@ samba:
|
|||||||
[global]
|
[global]
|
||||||
workgroup = WORKGROUP
|
workgroup = WORKGROUP
|
||||||
server string = %h server (Samba, Apline)
|
server string = %h server (Samba, Apline)
|
||||||
|
map to guest = bad user
|
||||||
|
|
||||||
[share]
|
[share]
|
||||||
path = /share
|
path = /share
|
||||||
browseable = yes
|
browseable = yes
|
||||||
read only = yes
|
read only = no
|
||||||
guest ok = yes
|
guest ok = yes
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -54,7 +55,16 @@ Retype new SMB password:******
|
|||||||
## client
|
## client
|
||||||
|
|
||||||
```
|
```
|
||||||
$ smbutil view smb://server
|
$ smbutil view -NG smb://server
|
||||||
|
Share Type Comments
|
||||||
|
-------------------------------
|
||||||
|
share Disk
|
||||||
|
IPC$ Pipe IPC Service (52e5ac2d2d7c server (Samba, Apline))
|
||||||
|
2 shares listed
|
||||||
|
|
||||||
|
$ mkdir -p /Volumes/share
|
||||||
|
$ mount_smbfs //guest@server/share /Volumes/share
|
||||||
|
$ umount /Volumes/share
|
||||||
```
|
```
|
||||||
|
|
||||||
[1]: https://www.samba.org/
|
[1]: https://www.samba.org/
|
||||||
|
Loading…
Reference in New Issue
Block a user