1
2
mirror of https://github.com/vimagick/dockerfiles synced 2024-07-05 09:31:24 +00:00
dockerfiles/samba/README.md

61 lines
882 B
Markdown
Raw Normal View History

2015-07-17 14:53:21 +00:00
samba
=====
2015-07-17 15:11:33 +00:00
![](https://badge.imagelayers.io/vimagick/samba:latest.svg)
[`Samba`][1] is the standard Windows interoperability suite of programs for
Linux and Unix.
## docker-compose.yml
```
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
restart: always
```
## smb.conf
```
[global]
workgroup = WORKGROUP
server string = %h server (Samba, Apline)
[share]
path = /share
browseable = yes
read only = yes
guest ok = yes
```
## server
```
$ cd ~/fig/samba
2015-07-17 15:50:28 +00:00
$ mkdir share
$ chmod 777 share
$ touch share/README.txt
2015-07-17 15:11:33 +00:00
$ docker-compose up -d
$ docker exec -it samba_samba_1 sh
2015-07-17 15:50:28 +00:00
>>> smbpasswd -a root
New SMB password:******
Retype new SMB password:******
2015-07-17 15:11:33 +00:00
>>> exit
```
## client
```
$ smbutil view smb://server
```
2015-07-17 14:53:21 +00:00
[1]: https://www.samba.org/