/docker-nas

Docker compose file which runs all of my apps which running at my NAS for daily usage

GNU General Public License v3.0GPL-3.0

docker-nas

Docker compose file which runs all of my apps which running at my NAS for daily usage

Prepare

  • Install docker, docker-compose on your server

Services included

Installation & Running

  • Install docker and docker-compose
  • Prepare .env by example of .env.example
  • Run docker-compose up -d

Setup

Most of setup configurations for Raspberry Pi

Mount SMB Share

Via sudo for once

sudo mount.cifs //192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared -o rw,user=username,password=xyzf,nounix,sec=ntlmssp,file_mode=0777,dir_mode=0777
# or
sudo mount.cifs //192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared -o user=username,password=xyzf,uid=1000,gid=1000,vers=3.0,nounix

and you can test via command sudo mount -a

Permanent mounting

Append following line into at end of /etc/stab

//192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared cifs credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,vers=3.0,nounix,noauto,x-systemd.automount

You can edit /etc/fstab file by sudo nano /etc/fstab, then reboot your device.

After reboot, check your path or run manually check via sudo mount -a

Docker mount wait

Guides / Tutorials
Documentation links
Possible fixes
Solution 1

Follow here

TLDR:

[Unit]
-After=network-online.target docker.socket firewalld.service containerd.service time-set.target
+After=network-online.target docker.socket firewalld.service containerd.service time-set.target local-fs.target

Try sudo nano /etc/systemd/system/multi-user.target.wants/docker.service (this path for Debian Raspberry) if above solution did not work

Solution 2

Follow here

TLDR:

[Unit]
-Requires=docker.socket
+Requires=docker.socket <your mount name>.mount
Solution 3

Follow here

TLDR:

-//192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared cifs credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,vers=3.0,nounix,noauto
+//192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared cifs credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,vers=3.0,nounix,noauto,x-systemd.automount
Solution 4

Follow here

TLDR:

-//192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared cifs credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,vers=3.0,nounix,noauto,x-systemd.automount
+//192.168.100.32/Media /home/pi/Desktop/docker-nas/data/shared cifs credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,vers=3.0,nounix,noauto,x-systemd.automount,x-systemd.idle-timeout=60,x-systemd.mount-timeout=30

Links