Code Monkey home page Code Monkey logo

docker-spotweb's Introduction

Dockerfile to set up Spotweb on ARM and X86 based systems

Build Status

The main goal of this Dockerfile is to easily set up Spotweb using Docker on the Raspberry Pi 2/3 (or any compatible ARM chipset) and regular X86 chipsets.

Quick setup using dockerfile

docker run -p 8080:80 --name spotweb -d -v /etc/localtime:/etc/localtime:ro erikdevries/spotweb

Provide one or more of the following environment variables to configure the database server (all optional, default values are given below):

  • DB_ENGINE (default = pdo_mysql)
  • DB_HOST (default = mysql)
  • DB_PORT (default = 3306)
  • DB_NAME (default = spotweb)
  • DB_USER (default = spotweb)
  • DB_PASS (default = spotweb)

E.g. to configure server with host some.external.mysql-server.com and port 6612 do the following:

docker run -p 8080:80 --name spotweb -d -v /etc/localtime:/etc/localtime:ro -e "DB_HOST=some.external.mysql-server.com" -e "DB_PORT=6612" erikdevries/spotweb

Quick setup using docker compose

  • docker-compose -f docker-compose-arm.yml up or docker-compose -f docker-compose-x86.yml up depending on cpu architecture
  • Visit http://localhost:8080
  • Login with username admin and password spotweb
  • Configure usenet server and wait for cronjob to update (runs once per hour)

Information

  • Spotweb is configured as an open system after running docker-compose up, so everyone who can access can register an account (keep this in mind)
  • If you want to use the Spotweb API, create a new user and use the API key associated with that user
  • If you would like to save nzb files to disk for (e.g.) SABnzbd to be picked up, configure docker-compose.yml to mount /nzb to some directory where nzb's need to be saved, and configure Spotweb to save NZB's to this directory on disk

Docker setup

I decided on the following setup for this Docker image:

  • Image contains NGINX, PHP 7.1 and Crond
  • For the database a second MySQL image is used (as the data stored in the db is nice to have, but not critical)
  • To prevent having to configure Spotweb manually upgrade-db.php is run to upgrade the database and reset the password for the admin user
  • Crond is used to run the retrieve.php script which updates Spotweb with the latest headers from a configured usenet server, the crontab is run every hour at 15 minutes past the whole hour
  • The only required manual configuration is setting up a valid usenet server
  • Depending on what you like, you can mount the /nzb volume and let Spotweb save nzb's to that directory (e.g. mount /nzb to a folder watched by sabnzbd)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.