initial commit

This commit is contained in:
fake 2020-05-14 18:04:52 -07:00
commit aa0e672a2a
3 changed files with 78 additions and 0 deletions

Dockerfile Normal file
View File

@ -0,0 +1,8 @@
FROM python:2
RUN bash /
ENTRYPOINT deluged && deluge-web --fork && bash

22 Normal file
View File

@ -0,0 +1,22 @@
# Premiere Deluge Docker
This helps build the premiere Deluge plugin and libtorrent inside of a Docker container.
To read more about what premiere mode does, see below.
#### How to install
1. Install Docker (instructions here <>)
2. Run `docker build . -t premiere-deluge` in the same directory as this repo's Dockerfile
3. Run `docker run --network host -it premiere-deluge` or `docker run -p 8112:8112 -it premiere-deluge`
4. You should be able to connect to the web UI running locally on port 8112
5. Default password is "deluge"
6. Right click torrents and select "Premiere Mode" to put them in premiere mode
#### What is "Premiere Mode"?
Setting a torrent to premiere mode causes all of its pieces to become
unavailble to peers except the first piece. After all peers in the swarm
have completely downloaded the first piece, the second piece gets announced
as available and peers may download it. This continues on until the last piece.
This plugin requires a forked version of libtorrent that supports setting pieces
into premiere mode.

48 Executable file
View File

@ -0,0 +1,48 @@
set -ex
git clone --depth=1
git clone --depth=1
git clone
git clone --depth=1 --branch=boost-1.72.0
apt update
apt install build-essential libssl-dev -y
pushd boost
git submodule update --init --depth=1
./b2 cxxstd=11 release install --with-python --with-system
pushd tools/build
./b2 install --prefix=/usr/
ln -s /usr/local/lib/ /usr/local/lib/
pushd premiere-libtorrent
git submodule update --init --recursive
b2 toolset=gcc link=shared variant=release target-os=linux address-model=64 crypto=openssl
cp bin/gcc-*/release/address-model-64/crypto-openssl/threading-multi/* /usr/local/lib
pushd bindings/python/
b2 toolset=gcc link=shared variant=release target-os=linux address-model=64 libtorrent-link=shared
cp bin/gcc*/release/address-model-64/lt-visibility-hidden/python-2.7/ /usr/local/lib/python2.7/site-packages
pushd deluge
pip install .
sleep 3
pkill -f deluged
pushd premiere-deluge-plugin
python bdist_egg
cp dist/*.egg ~/.config/deluge/plugins