Bravo List
Go Back   > Bravo List > P2P > Forum > Tutorials
Old 14-11-11, 18:05
sergiu4995's Avatar
sergiu4995 sergiu4995 is offline
Join Date: Nov 2011
Posts: 11
Default Deluge 1.2.0 and flexget up and running in 30mins
This tutorial requires terminal usage skills and that you have macports installed (thus requiring xcode installed aswell). If you don't understand anything of this, don't even try to follow this tutorial.

This tutorial will guide you on how to install Deluge 1.2.0 final and flexget in a clean and non-messy way with virtualenv and python 2.6 in Snowleopard. Virtualenv is a way to isolate python installations. Some may say that macports it self is a self contained isolation but if you do a lot of python development you may want to run different libs in different versions side by side. Let's just say it's good practice to keep your macports clean. It will take 30-60 minutes depending on your computers speed.

Anyway lets get going by starting to install python, boost etc and then deluge. We finish with installing flexget in the last steps.

1. sudo port install openssl gettext python26 +no_tkinter py26-setuptools python_select boost +python26 py26-game py26-gtk librsvg libnotify
(+no_tkinter builds python without unesscary x11 libs, who the fck uses IDLE anyway?) (This will take some time depending on your machine)
2. sudo python_select python26
3. sudo easy_install virtualenv virtualenvwrapper pip
4. Put this in your ~/.bashrc or modify it to zsh or whatever you are using and put it in corresponding rc file.

export PATH="/opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin:$PATH"

export WORKON_HOME='/Users/<user>/virtualenvs'

if [ -f /opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/virtualenvwrapper_bashrc ]; then
. /opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin/virtualenvwrapper_bashrc

5. source ~/.bashrc or whatever rc file you added the above to (or logout and login)
6. mkvirtualenv deluge
7. easy_install pyOpenSSL Mako Twisted pygeoip chardet pyxdg
8. Go to and find the download link for the latest pyxdg
9. easy_install (replace with the link from step 6)
10. cd $WORKON_HOME/deluge && mkdir src && cd src
11. Get latest deluge from (wget ... .0.tar.bz2)
12. Get the source code for rasterbar libtorrent - NOT THE LIBTORRENT THAT COMES WITH MACPORTS NOR THE LIBTORRENT THAT COMES WITH RTORRENT - from (wget ... 4.8.tar.gz) or the appropriate link for you.
13. tar -xvjf deluge*.tar.bz2 && tar -xvzf libtorrent-rasterbar*.tar.gz && mv $(ls -d libtorrent-rasterbar*/) $(ls -d deluge*/)/libtorrent && cd $(ls -d deluge*/) && ln -s /opt/local/include/boost libtorrent/include/
14. Time to compile deluge and libtorrent. run python install
15. Get coffe or take a dump. This will take some minutes.
16. Test that deluge works with deluge -u web -L debug
17. If deluged runs fine (and it should if you did it right), ctrl+c to quit it. If it does'nt cry a river
18. Copy plugins into the correct place so that they will run. (cp deluge/plugins/*.egg ~/.config/deluge/plugins)
19. Edit your config in ~/.config/deluge to fit your needs ()
20. crontab -e and add this rows, replace <username> with your username:
@reboot source /Users/<username>/virtualenvs/deluge/bin/activate && deluged > /dev/null 2>&1 &
@reboot source /Users/<username>/virtualenvs/deluge/bin/activate && deluge-web -f > /dev/null 2>&1

Deluge is now installed in a virtualenv which we named deluge. If you log on to a new shell and type deluge it will not work.
However if you typ workon you will get a list of your available virtualenvs. Type workon deluge to work on the deluge virtualenv and be able to run deluge or deluge-console

Thanks comedian for the tutorial which this is based up on (viewtopic.php?f=13&t=26085).


Getting flexget to work with deluge now is just a matter of installing flexget in the same virtualenv as deluge.

1. Type workon deluge in your terminal unless you are still in the same environment as above
2. Go to and copy the download link for the latest version
3. easy_install ... -py2.6.egg (replace with link to latest version)
4. Edit your config and initdb
5. crontab -e and add this to make flexget run each fifth minute of the hour:
*/5 * * * * source /Users/<username>/virtualenvs/deluge/bin/activate && flexget --cron > /dev/null 2>&1
Reply With Quote

30mins , deluge , flexget , running

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 07:32. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2018, vBulletin Solutions Inc.