Skip to content

paprikodlak/LMDS

 
 

Repository files navigation

LMDS Stack

Linux Media Delivery System Stack based on Docker for Raspberry Pi Originally GreenFrogSB, then modified using the lessons learned while deploying it on the Raspberry Pi 4 8GB

Todo

Set up volumes such as https://wiki.servarr.com/Docker_Guide, https://trash-guides.info/Misc/how-to-set-up-hardlinks-and-atomic-moves/#docker.

My own deploy strategy

  • install git using a command:
sudo apt-get install git
  • Clone the repository with:
git clone https://github.com/GreenFrogSB/LMDS.git ~/LMDS

Do not change name of the folder on your local system it should stay as is for the script to work properly

  • Enter the directory and run:
cd ~/LMDS
  1. Use the ./deploy.sh script to install docker.
  2. Use the ./deploy.sh to create stack.
  3. Copy docker-compose_paprikodlak.yml to docker-compose.yml.
  4. Customize .env.example, rename to .env. Check id pi for uid a gid.
  5. Run docker-compose up -d, let it bring it up and then docker-compose down.
  6. Use sudo chown -R pi:pi volumes to fix permissions.
  7. Fix the problem with dhcpcd dying after boot by putting denyinterfaces veth* to he beginning of /etc/dhcpcd.conf, as stated here.
  8. Put jdownloader-block.txt into the download folder, run it manually using docker exec -it jdownloader sh, run jdownloader using java -jar JDownloader.jar -norestart and set it up. Then delete the .txt file.
  9. Set up the PIA openVPN: to download the OpenVPN configuration files and certs is: https://www.privateinternetaccess.com/openvpn/openvpn-nextgen.zip, once you have downloaded the zip (normally a zip as they contain multiple ovpn files) then extract it to /config/openvpn/ folder (if that folder doesn't exist then start and stop the docker container to force the creation of the folder). If there are multiple ovpn files then please delete the ones you don't want to use (normally filename follows location of the endpoint) leaving just a single ovpn file and the certificates referenced in the ovpn file (certificates will normally have a crt and/or pem extension).
  10. To fix the problem with Bazarr on RPi 4, run wget http://ftp.us.debian.org/debian/pool/main/libs/libseccomp/libseccomp2_2.5.1-1_armhf.deb, sudo dpkg -i libseccomp2_2.5.1-1_armhf.deb
  11. For the services interlinking, use the IPV4 IPAM Gateway IP of the bridge. In Heimdall, use external RPi IP adress or its assigned domain name.

Menu

Install docker

First "Install docker" this might take a while. Process will install latest Docker and Docker-compose for ARM. When installation is completed you will be prompted to reboot, please do so before continuing.

Build LMDS Stack

Next "Build LMDS Stack", select docker containers that you would like to pull and deploy. You do not have to select them all, select only the one you will use. Selecting only the one you need will reduce RAM consumption on your Pi what might be a problem on RPi 3, not so much on RPi 4 I guess. I do not have RPi 4 so I was only able to test it on my old RPi 3B SBC

You might like to install Portainer among all the other containers - Portainer is a graphical interface that lets you manage Docker engine - very useful tool if you don’t want to use Docker CLI.

Docker commands

This small section contains few useful commands in case your Portainer is not started and you would like to get something done without the GUI.

Miscellaneous commands.

There are three scripts that can be used in case you would like to disable swapping to your SD card. You might want to do it in order to extend life of your SD card. SD cards were not designed for intensive IO tasks, therefore using them like normal HDDs is not ideal. Swap file is used to offload your RAM in case of OS need to dump it somewhere. Swap will be quite often modify, what might wear out your SD card in a long run. In other hand if your OS is swapping a lot of data it means his RAM size is generally to small - this might be a case on RPi3 where we have only 1GB of RAM.

Update LMDS Stack

Each time you run ./deploy.sh script will check GitHub repository for any updates and download them if available. You can also manually check for update using this option without running ./deploy.sh script. Updates will not modify your configuration or any private files except the ones that are part of the LMDS logic. Some new functions might be added or new containers etc.

About

LMDS - Linux Media Delivery System

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 100.0%