Skip to content

How to deploy with a single docker-compose file? #272

@injeolmibingsoo

Description

@injeolmibingsoo

Hello. I love bobarr for being a one-stop-shop for movies/tv shows and have been trying to set it up on my home server for a while now.

What I would like to do, however, is to have all of the configuration in a single docker-compose file, instead of running the prescribed installation and start-up scripts. This allows me to better organize where certain files go where (e.g. config files in my cache drive). In addition, I also wanted to run bobarr with azinchen's nordvpn docker client, which I found to be the easiest way to have services run through my subscription of nordvpn.

I therefore took the provided bobarr/docker-compose.yml and started to add environmental variables from bobarr/.env and azinchen's nordvpn stuff.

Bear in mind that I'm basically a "script kiddie" when it comes to docker. I am okay with making small modifications to example compose files, but don't really understand how it all comes together behind the hood. I hence apologize in advance if I made any gross mistakes in the following compose file.

This is the current version of said compose file, which I am able to deploy. While I did not run into any error during the deployment, the server is not fully functional. I got as far as being able to add movies on the bobarr interface, but couldn't find the downloads starting on transmission.

I'd appreciate any feedback/tips to get this to work. Thanks!

version: "3.6"

volumes:
  web_build:
  api_build:
  api_node_modules:
  web_node_modules:
  db_data:
  redis_data:

networks:
  default:

services:    
  api:
    container_name: bobarr-api
    environment:
      - ENV=production
      - PUID=3001
      - PGID=3001
      - UMASK_SET=0002
      - TZ=US/Eastern        
      - POSTGRES_DB=bobarr
      - POSTGRES_USER=bobarr
      - POSTGRES_PASSWORD=bobarr    
      - REDIS_PASSWORD=bobarr
      - DEBUG_REDIS=false      
      - JACKETT_AUTOMATIC_SEARCH_TIMEOUT=120000
      - JACKETT_MANUAL_SEARCH_TIMEOUT=15000      
      - LIBRARY_MOVIES_FOLDER_NAME=movies
      - LIBRARY_TV_SHOWS_FOLDER_NAME=tvshows
    image: iam4x/bobarr-api:latest
    command: yarn start:prod
    restart: unless-stopped
    volumes:
      - /mnt/ssd1/media/bobarr:/usr/library
    ports:
      - 4000:4000
#     links:
#       - vpn:transmission
#     networks:
#       - default

  web:
    container_name: bobarr-web
#     environment: 
#       - WEB_UI_API_URL=http://yourdomain.com/api
    image: iam4x/bobarr-web:latest
    command: yarn start
    restart: unless-stopped
    ports:
      - 3000:3000
#     links:
#       - vpn:transmission
#     networks:
#       - default      

  postgres:
    container_name: bobarr-postgresql
    image: postgres:12-alpine
    environment:
      - POSTGRES_DB=bobarr
      - POSTGRES_USER=bobarr
      - POSTGRES_PASSWORD=bobarr
    restart: unless-stopped
    volumes:
      - db_data:/var/lib/postgresql/data

  redis:
    container_name: bobarr-redis
    image: bitnami/redis:5.0.6
    environment:
      - REDIS_PASSWORD=bobarr
      - DEBUG_REDIS=false
    restart: unless-stopped
    volumes:
      - redis_data:/bitnami/redis/data

  jackett:
    image: linuxserver/jackett
    container_name: bobarr-jacket
    environment:
      - PUID=3001
      - PGID=3001   
      - UMASK_SET=0002
      - TZ=US/Eastern      
      - JACKETT_AUTOMATIC_SEARCH_TIMEOUT=120000
      - JACKETT_MANUAL_SEARCH_TIMEOUT=15000
    restart: unless-stopped
    volumes:
      - /mnt/ssd0/appdata/jackett/config:/config
      - /mnt/ssd1/media/bobarr/jackett:/downloads
    ports:
      - 9117:9117  
#     network_mode: service:vpn      
#     depends_on:
#       - vpn      

  flaresolverr:
    image: ghcr.io/flaresolverr/flaresolverr:latest
    container_name: bobarr-flaresolverr
    environment:
      - LOG_LEVEL=info
    restart: unless-stopped
    ports:
      - 8191:8191

  transmission:
    image: linuxserver/transmission
    container_name: bobarr-transmission
    environment:
      - PUID=3001
      - PGID=3001
      - UMASK_SET=0002
      - TZ=US/Eastern        
    restart: unless-stopped
    volumes:
      - /mnt/ssd1/media/bobarr/downloads:/downloads
      - /mnt/ssd0/appdata/transmission/config:/config
      - /mnt/ssd0/appdata/transmission/watch:/watch
    network_mode: service:vpn      
    depends_on:
      - vpn      

#   transmission-web:
#     image: dperson/nginx
#     container_name: bobarr-transmission-web
#     depends_on:
#       - transmission
#     environment:
#       - TZ=US/Eastern
#     ports:
#       - "9091:81"
#     command: -w "http://transmission:9091;/"
#     restart: unless-stopped

  vpn:
    image: azinchen/nordvpn:latest
    network_mode: bridge
    container_name: bobarr-nordvpnwireguard
    cap_add:
      - net_admin
    devices:
      - /dev/net/tun
    environment:
      - USER=[nordvpn-user]
      - PASS=[nordvpn-pass]
      - COUNTRY=[nordvpn-country]
      - GROUP=P2P
      - TECHNOLOGY=openvpn_udp
      - RANDOM_TOP=10
      - RECREATE_VPN_CRON=5 */3 * * *
      - NETWORK=192.168.1.0/24
      - OPENVPN_OPTS=--mute-replay-warnings
    ports:
#       - 9117:9117  ## Jackett
      - 9091:9091  ## Transmission
      - 51413:51413  ## Transmission
      - 51413:51413/udp  ## Transmission

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions