Skip to content

Commit

Permalink
dev: more doc work
Browse files Browse the repository at this point in the history
  • Loading branch information
da2ce7 committed Aug 29, 2023
1 parent 70177cc commit 8c4f9f1
Show file tree
Hide file tree
Showing 5 changed files with 193 additions and 143 deletions.
1 change: 0 additions & 1 deletion .env.local

This file was deleted.

92 changes: 69 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Torrust Tracker

[![Build & Release](https://github.com/torrust/torrust-tracker/actions/workflows/build_release.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/build_release.yml) [![CI](https://github.com/torrust/torrust-tracker/actions/workflows/test_build_release.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/test_build_release.yml) [![Publish crate](https://github.com/torrust/torrust-tracker/actions/workflows/publish_crate.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/publish_crate.yml) [![Publish docker image](https://github.com/torrust/torrust-tracker/actions/workflows/publish_docker_image.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/publish_docker_image.yml) [![Test](https://github.com/torrust/torrust-tracker/actions/workflows/test.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/test.yml) [![Test docker build](https://github.com/torrust/torrust-tracker/actions/workflows/test_docker.yml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/test_docker.yml) [![Coverage](https://github.com/torrust/torrust-tracker/actions/workflows/coverage.yaml/badge.svg)](https://github.com/torrust/torrust-tracker/actions/workflows/coverage.yaml)
[![container_wf]][container_wf_b] [![coverage_wf]][coverage_wf_b] [![testing_wf]][testing_wf_b]

Torrust Tracker is a lightweight but incredibly high-performance and feature-rich BitTorrent tracker written in [Rust](https://www.rust-lang.org/).
Torrust Tracker is a lightweight but incredibly high-performance and feature-rich BitTorrent tracker written in [Rust].

It aims to provide a reliable and efficient solution for serving torrents to a vast number of peers while maintaining a high level of performance, robustness, extensibility, security, usability and with community-driven development.

Expand All @@ -14,19 +14,19 @@ It aims to provide a reliable and efficient solution for serving torrents to a v
* [X] Built-in API.
* [X] Torrent whitelisting.
* [X] Peer authentication using time-bound keys.
* [X] [newTrackon](https://newtrackon.com/) check is supported for both HTTP and UDP, where IPv4 and IPv6 are properly handled.
* [X] [newTrackon] check is supported for both HTTP and UDP, where IPv4 and IPv6 are properly handled.
* [X] SQLite3 and MySQL persistence, loading and saving of the torrent hashes and downloads completed count.
* [X] Comprehensive documentation.
* [X] A complete suite of tests. See [code coverage](https://app.codecov.io/gh/torrust/torrust-tracker) report.
* [X] A complete suite of tests. See our code [coverage] report.

## Implemented BEPs

* [BEP 3](https://www.bittorrent.org/beps/bep_0003.html): The BitTorrent Protocol.
* [BEP 7](https://www.bittorrent.org/beps/bep_0007.html): IPv6 Support.
* [BEP 15](http://www.bittorrent.org/beps/bep_0015.html): UDP Tracker Protocol for BitTorrent.
* [BEP 23](http://bittorrent.org/beps/bep_0023.html): Tracker Returns Compact Peer Lists.
* [BEP 27](http://bittorrent.org/beps/bep_0027.html): Private Torrents.
* [BEP 48](http://bittorrent.org/beps/bep_0048.html): Tracker Protocol Extension: Scrape.
* [BEP 03]: The BitTorrent Protocol.
* [BEP 07]: IPv6 Support.
* [BEP 15]: UDP Tracker Protocol for BitTorrent.
* [BEP 23]: Tracker Returns Compact Peer Lists.
* [BEP 27]: Private Torrents.
* [BEP 48]: Tracker Protocol Extension: Scrape.

## Getting Started

Expand All @@ -35,7 +35,7 @@ Requirements:
* Rust Stable `1.68`
* You might have problems compiling with a machine or docker container with low resources. It has been tested with docker containers with 6 CPUs, 7.5 GM of memory and 2GB of swap.

You can follow the [documentation](https://docs.rs/torrust-tracker/) to install and use Torrust Tracker in different ways, but if you want to give it a quick try, you can use the following commands:
You can follow the [documentation] to install and use Torrust Tracker in different ways, but if you want to give it a quick try, you can use the following commands:

```s
git clone https://github.com/torrust/torrust-tracker.git \
Expand All @@ -45,11 +45,11 @@ git clone https://github.com/torrust/torrust-tracker.git \
&& mkdir -p ./storage/tracker/lib/tls
```

The tracker gets it's default configuration from the [share/default/config](./share/default/config/) folder: either [´tracker.development.sqlite3.toml´](./share/default/config/tracker.development.sqlite3.toml), the [local default](./src/bootstrap/config.rs#L18); or [′tracker.container.sqlite3.toml´](./share/default/config/tracker.container.sqlite3.toml), the [container default](./share/container/entry_script_s#L10).
The tracker gets it's default configuration from the [share/default/config] folder: either [´tracker.development.sqlite3.toml´], the [local default]; or [′tracker.container.sqlite3.toml´], the [container default].

To specify a different configuration file, supply it's path on an environmental variable: [`TORRUST_TRACKER_PATH_CONFIG`](./src/bootstrap/config.rs#L15), or simply supply your entire configuration on the environmental variable itself: [`TORRUST_TRACKER_CONFIG`](./src/bootstrap/config.rs#L11).
To specify a different configuration file, supply it's path on an environmental variable: [`TORRUST_TRACKER_PATH_CONFIG`], or simply supply your entire configuration on the environmental variable itself: [`TORRUST_TRACKER_CONFIG`].

You can also supply the api administration token via an environmental variable: [`ENV_VAR_API_ADMIN_TOKEN`](./src/bootstrap/config.rs#L12).
You can also supply the api administration token via an environmental variable: [`ENV_VAR_API_ADMIN_TOKEN`].

After running the tracker these services will be available (as defined in the default configuration):

Expand All @@ -59,10 +59,10 @@ After running the tracker these services will be available (as defined in the de

## Documentation

* [Crate documentation](https://docs.rs/torrust-tracker/).
* [API `v1`](https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/apis/v1).
* [HTTP Tracker](https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/http).
* [UDP Tracker](https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/udp).
* [Crate documentation]
* [API `v1`]
* [HTTP Tracker]
* [UDP Tracker]

## Contributing

Expand All @@ -71,16 +71,62 @@ We welcome contributions from the community!
How can you contribute?

* Bug reports and feature requests.
* Code contributions. You can start by looking at the issues labeled ["good first issues"](https://github.com/torrust/torrust-tracker/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22).
* Documentation improvements. Check the [documentation](https://docs.rs/torrust-tracker/) and [API documentation](https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/apis/v1) for typos, errors, or missing information.
* Participation in the community. You can help by answering questions in the [discussions](https://github.com/torrust/torrust-tracker/discussions).
* Code contributions. You can start by looking at the issues labeled "[good first issues]".
* Documentation improvements. Check the [documentation] and [API documentation] for typos, errors, or missing information.
* Participation in the community. You can help by answering questions in the [discussions].

## License

The project is licensed under a dual license. See [COPYRIGHT](./COPYRIGHT).
The project is licensed under a dual license. See [COPYRIGHT].

## Acknowledgments

This project was a joint effort by [Nautilus Cyberneering GmbH](https://nautilus-cyberneering.de/) and [Dutch Bits](https://dutchbits.nl). Also thanks to [Naim A.](https://github.com/naim94a/udpt) and [greatest-ape](https://github.com/greatest-ape/aquatic) for some parts of the code. Further added features and functions thanks to [Power2All](https://github.com/power2all).
This project was a joint effort by [Nautilus Cyberneering GmbH] and [Dutch Bits]. Also thanks to [Naim A.] and [greatest-ape] for some parts of the code. Further added features and functions thanks to [Power2All].



[container_wf]: https://github.com/torrust/torrust-tracker/actions/workflows/container.yaml
[container_wf_b]: https://github.com/torrust/torrust-tracker/actions/workflows/container.yaml/badge.svg
[coverage_wf]: https://github.com/torrust/torrust-tracker/actions/workflows/coverage.yaml
[coverage_wf_b]: https://github.com/torrust/torrust-tracker/actions/workflows/coverage.yaml/badge.svg
[testing_wf]: https://github.com/torrust/torrust-tracker/actions/workflows/testing.yaml
[testing_wf_b]: https://github.com/torrust/torrust-tracker/actions/workflows/testing.yaml/badge.svg

[Rust]: https://www.rust-lang.org/
[newTrackon]: https://newtrackon.com/
[coverage]: https://app.codecov.io/gh/torrust/torrust-tracker

[BEP 03]: https://www.bittorrent.org/beps/bep_0003.html
[BEP 07]: https://www.bittorrent.org/beps/bep_0007.html
[BEP 15]: http://www.bittorrent.org/beps/bep_0015.html
[BEP 23]: http://bittorrent.org/beps/bep_0023.html
[BEP 27]: http://bittorrent.org/beps/bep_0027.html
[BEP 48]: http://bittorrent.org/beps/bep_0048.html

[share/default/config]: ./share/default/config/
[´tracker.development.sqlite3.toml´]: ./share/default/config/tracker.development.sqlite3.toml
[local default]: ./src/bootstrap/config.rs#L18
[′tracker.container.sqlite3.toml´]: ./share/default/config/tracker.container.sqlite3.toml
[container default]: ./share/container/entry_script_s#L10

[`TORRUST_TRACKER_PATH_CONFIG`]: ./src/bootstrap/config.rs#L15
[`TORRUST_TRACKER_CONFIG`]: ./src/bootstrap/config.rs#L11
[`ENV_VAR_API_ADMIN_TOKEN`]: ./src/bootstrap/config.rs#L12

[Crate documentation]: https://docs.rs/torrust-tracker/
[API `v1`]: https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/apis/v1
[HTTP Tracker]: https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/http
[UDP Tracker]: https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/udp

[good first issues]: https://github.com/torrust/torrust-tracker/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22
[documentation]: https://docs.rs/torrust-tracker/
[API documentation]: https://docs.rs/torrust-tracker/3.0.0-alpha.3/torrust_tracker/servers/apis/v1
[discussions]: https://github.com/torrust/torrust-tracker/discussions

[COPYRIGHT]: ./COPYRIGHT

[Nautilus Cyberneering GmbH]: https://nautilus-cyberneering.de/
[Dutch Bits]: https://dutchbits.nl
[Naim A.]: https://github.com/naim94a/udpt
[greatest-ape]: https://github.com/greatest-ape/aquatic
[Power2All]: https://github.com/power2all
10 changes: 5 additions & 5 deletions compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ name: torrust
services:

tracker:
image: torrust-tracker:debug
image: torrust-tracker:release
tty: true
environment:
- TORRUST_TRACKER_DATABASE=${TORRUST_TRACKER_DATABASE:-"mysql"}
- TORRUST_TRACKER_DATABASE=${TORRUST_TRACKER_DATABASE:-mysql}
- TORRUST_TRACKER_API_ADMIN_TOKEN=${TORRUST_TRACKER_API_ADMIN_TOKEN:-MyAccessToken}
networks:
- server_side
Expand All @@ -14,9 +14,9 @@ services:
- 7070:7070
- 1212:1212
volumes:
- ./storage/tracker/lib:/var/lib/torrust/tracker
- ./storage/tracker/log:/var/log/torrust/tracker
- ./storage/tracker/etc:/etc/torrust/tracker
- ./storage/tracker/lib:/var/lib/torrust/tracker:Z
- ./storage/tracker/log:/var/log/torrust/tracker:Z
- ./storage/tracker/etc:/etc/torrust/tracker:Z
depends_on:
- mysql

Expand Down
Loading

0 comments on commit 8c4f9f1

Please sign in to comment.