Seeding
|
Example: Torrent creation and seeding using the internal tracker
s = Session().get_instance()
tdef = TorrentDef()
tdef.add_content('/tmp/HelloWorld.wmv')
tdef.set_tracker(s.get_internal_tracker_url())
tdef.finalize()
dscfg = DownloadStartupConfig()
dscfg.set_dest_dir('/tmp')
d = s.start_download(tdef,dscfg)
In the first part a new torrent is created containing your home brew video file using your own internal tracker. This follows the standard Bittorrent protocol. The second part starts the downloading/seeding protocol as usual. |