diff --git a/README.md b/README.md index f115a17..f65112c 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,7 @@ dockerfiles - [x] rsyncd - [x] rtmp - [x] samba :+1: +- [x] samba-arm :+1: - [x] scrapyd :+1: - [x] shadowsocks - [x] shadowsocks diff --git a/samba/arm/Dockerfile b/samba/arm/Dockerfile new file mode 100644 index 0000000..aa5b70e --- /dev/null +++ b/samba/arm/Dockerfile @@ -0,0 +1,22 @@ +# +# Dockerfile for samba-arm +# + +FROM easypi/alpine-arm +MAINTAINER EasyPi Software Foundation + +RUN set -xe \ + && apk add -U samba-common-tools samba-server \ + && rm -rf /var/cache/apk/* + +COPY smb.conf /etc/samba/ + +VOLUME /etc/samba \ + /var/lib/samba + +EXPOSE 137/udp \ + 138/udp \ + 139/tcp \ + 445/tcp + +CMD nmbd -D && smbd -FS diff --git a/samba/arm/docker-compose.yml b/samba/arm/docker-compose.yml new file mode 100644 index 0000000..e6ff8a5 --- /dev/null +++ b/samba/arm/docker-compose.yml @@ -0,0 +1,8 @@ +samba: + image: easypi/samba-arm + volumes: + - ./smb.conf:/etc/samba/smb.conf + - /mnt/usb:/share + net: host + tty: yes + restart: always diff --git a/samba/mnt-usb.mount b/samba/arm/mnt-usb.mount similarity index 100% rename from samba/mnt-usb.mount rename to samba/arm/mnt-usb.mount diff --git a/samba/arm/smb.conf b/samba/arm/smb.conf new file mode 100644 index 0000000..d7e0382 --- /dev/null +++ b/samba/arm/smb.conf @@ -0,0 +1,33 @@ +[global] +netbios name = easypi +workgroup = WORKGROUP +server string = EasyPi Samba Server +dns proxy = no +log file = /var/log/samba/log.%m +max log size = 1000 +syslog = 0 +panic action = /usr/share/samba/panic-action %d +server role = standalone server +passdb backend = tdbsam +obey pam restrictions = yes +unix password sync = yes +passwd program = /usr/bin/passwd %u +passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* . +pam password change = yes +map to guest = bad user +usershare allow guests = yes +printcap name = /dev/null +load printers = no + +[homes] +comment = Home Directories +browseable = no +writable = yes + +[share] +path = /share +browseable = yes +read only = no +guest ok = yes +admin users = root +root preexec = mkdir -p /share diff --git a/samba/smb.conf.sample b/samba/arm/smb.conf.sample similarity index 100% rename from samba/smb.conf.sample rename to samba/arm/smb.conf.sample diff --git a/samba/docker-compose.yml b/samba/docker-compose.yml index 9a309d8..9fa0c19 100644 --- a/samba/docker-compose.yml +++ b/samba/docker-compose.yml @@ -2,7 +2,7 @@ samba: image: vimagick/samba volumes: - ./smb.conf:/etc/samba/smb.conf - - /mnt/usb:/share + - ./share:/share net: host tty: yes restart: always