karamanolev / WhatManager2

Torrent management system based on Django and Transmission
MIT License
153 stars 25 forks source link

Docker support #103

Open faircopy opened 7 years ago

faircopy commented 7 years ago

Some things can possibly be improved, but it's a start.

I can make the Docker stuff a separate GitHub repo as well, let me know what you think.

karamanolev commented 7 years ago

@faircopy Docker support makes me very happy. Since I don't have the time to test this ATM, can you have some other people test it as well? Maybe people will see this here or you can recruit them in the forums. Another point - will you be able to make a Wiki page that's a guide for how to run this and how management becomes different?

faircopy commented 7 years ago

@karamanolev Sure, I can ask people to give it a go. There's a detailed README included, which is where I thought to keep all the related information. I can move or copy that to the Wiki so people are able to edit it.

karamanolev commented 7 years ago

@faircopy If you think this is ready to go I can merge it now.

casedefault commented 7 years ago

@karamanolev @faircopy I've just done a quick smoke test of this. Newly installed Docker for Mac, followed the instructions in the README to set it up. I've tested that the transmission instance is up and running and I can connect to it (using Transmission Remote GUI) and that the WM2 web interface is available and appears to work. But it's not connected to a RED user and I'm not going to download any torrents as this is just a quick test.

But I see no reason why I shouldn't try and migrate my 'production' set up over to this as it seems well thought out. I just need the time!

faircopy commented 7 years ago

@karamanolev, I'd like to modify some of the Compose file based on @casedefault's recommendations and test it some more, so please don't merge yet.

karamanolev commented 7 years ago

@faircopy Just keep this thread updated and I'll merge it when you are.

LennyPenny commented 6 years ago

Any update on its stability? Would love to switch to this

faircopy commented 6 years ago

@LennyPenny I'll try and finish up over the weekend, this project's been haunting me for a long time now. :ghost:

I wouldn't recommend using it yet, there's redundancy in the configuration as well as the setup process. I've been refactoring the Compose definition according to the DRY principle, that part works fine.

The main obstacle is that I wanted to be able to scale Transmission using either docker-compose scale or docker service scale, as opposed to copy-pasting sections in the Compose definitions. The former doesn't seem to be possible, lacking a way to use persistent data volumes. The latter (Docker Swarm) would only work when used on a single node, volumes don't move across swarm nodes.

Todo

karamanolev commented 6 years ago

@faircopy You're doing an amazing job. Please keep it up!

faircopy commented 6 years ago

Sadly, Transmission instances can only be defined by having the actual service definitions repeated in the Compose file. I've hacked together a script in POSIX Shell to automate this.

Sharing configuration settings between Compose files is not possible. Compose extension fields work by using YAML anchors, and those don't work across files.

So it'll have to be a single monolithic Compose file, if we want to have settings like timezone defined only once. There'll be a separate configuration section at the beginning of the file. Transmission service definitions are generated by a script, and will need to be pasted manually into the Compose file, whenever instance count needs changing.

I'll try and make it so that no other files need manual editing.

The most automatic thing would be a program that takes a single config file as an input, and outputs a single Compose file. Maybe later (probably never), for now I'll complete the rest of the todo list so we can have a usable setup. :slightly_smiling_face:

LennyPenny commented 5 years ago

@faircopy is this in a usable state now? I'm very excited

LennyPenny commented 5 years ago

I will just try it out and provide some feedback :)

LennyPenny commented 5 years ago

Okay I got it running, its working perfectly! I don't think the transcoder is working though, is that out of scope for this PR?