-
This is probably simpler as a question than this convoluted one. Inputs:
The bittorent spec list those steps. To start serving, a host goes through the following steps:
Step 4 can be done programmatically. 2 related questions, with the documentation tag, both a bit abandoned.
I think having a solution where one can run a set of commands (from the cmd/) folder would be awesome ; I don't know how people debug but that's what I do. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 9 replies
-
Sorry the documentation is very sparse here, it's hard to get time with also being flat out actually implementing stuff 😆 . You can create the torrent file per step 4, by using |
Beta Was this translation helpful? Give feedback.
-
PrerequisiteMake sure you have version v1.31.0 of anacrolix/torrent. Step 1 - Compile torrent commandsIn a new terminal (1), we will clone the anacrolix repo and generate 2 binaries in /tmp/
Step 2 - Run a local trackerIn a new terminal (2), we will build and run chihaya with the default config.
Step 3 - Generate torrent and seed file with a first clientIn a new terminal (3), run the commands below. We will make some temp dirs, and create a new fake file that we will seed. Notice how we are passing the -n option (to strip default trackers from the generated torrent ; I need to do that as my mac is behind a firewall), and then the -a option to add the udp url of the locally running chihaya. Generate torrent
Seed fileRun this command from the same folder. We pass the --addr :9002 as I get errors with the default port. Your mileage might vary here, change the port if the one below does not work for you.
Step 4 - Download the torrent with a second clientIn a new terminal (4), navigate to your local anacrolix/torrent repo and download the file.
You downloaded your file !!! |
Beta Was this translation helpful? Give feedback.
Prerequisite
Make sure you have version v1.31.0 of anacrolix/torrent.
Step 1 - Compile torrent commands
In a new terminal (1), we will clone the anacrolix repo and generate 2 binaries in /tmp/
Step 2 - Run a local tracker
In a new terminal (2), we will build and run chihaya with the default config.