torrust / torrust-index Goto Github PK
View Code? Open in Web Editor NEWThis repository serves as the backend for the Torrust Index project.
Home Page: https://torrust.com
License: GNU Affero General Public License v3.0
This repository serves as the backend for the Torrust Index project.
Home Page: https://torrust.com
License: GNU Affero General Public License v3.0
Basically as the title says.
The advantage of this would be that an OpenApi V2 specification can be automatically generated from the code. This would be helpful for those implementing client libraries for Torrust. It should be quite trivial to add too, I'd be more than happy to PR this.
Thanks.
[moved from here /issues/82]
this is a pretty painful bug, i actually thought there was an issue open already.
in short:
user logs in
user doesn't log out and keeps the same session active for X amount of weeks
eventually the session will time out (but they will still show as logged in) and any torrents they download won't work - they show as "400 error unauthenticated" - AKA no passkey.
Having users do this:
Delete the torrent from the client
Sign out from the site
Sign back in again and download the torrent fresh
re-add new torrent - this fixes it.
This would be a huge QOL improvement for us - again, thanks so much guys, you're the best
Deleting a category also deletes all the torrents in that category. A warning for that should be displayed
Advance user like this
Setting both the db_driver
and connect_url
in the config.toml
shouldn't be necessary. The db_driver
can be derived from the connect_url
.
Need to add comment section for the posts
Link: https://torrust.com/torrust-web-backend/about/
On this line: https://github.com/torrust/torrust-index-backend/blob/main/README.md?plain=1#L37
## Documentation
You can read the documentation [here](https://torrust.github.io/torrust-documentation/torrust-web-backend/about/).
## Installation
Apply the new contributor agreement version
User profile section where everyone can see the post of specific user by clicking on his name from the post.
Torrust needs at least one administrator account. On first boot it should show an install wizard to create an admin account and to set the tracker/website config.
Could be done using the config.toml in the backend (add an option in the settings page)
Need to add a option using which we can let user describe if it is 18+ content
I can create an account with test
as email address. This should not be possible as test
is not a valid email address.
User authentication is currently done manually in each endpoint that requires authentication. Ideally, we would have an authentication middleware instead. The authentication middleware could pass Option<User>
to the endpoint handler.
Currently, authorization is handled by each handler on its own. We should translate this logic into actions that will be authorized by a service that checks whether the user that invoked the action has the proper permissions to do so.
Hello,
Just an idea
Adding a trusted uploaders badge can make the big difference in users when they have multiple post of same series by different uploader.
Thanks
Nice to have an option to disable Registration or only with invite code. Or Admins can add Users Accounts
An option for users to report torrents would be very useful. I think a quick and dirty way of implementing something like this might be via giving the user a small modal to explain why, then trigger a webhook (rather than creating a section within the ACP for example).
Allowing users to create pages using markdown
Users can upload torrents while the backend does not have a connection with the tracker. This will result in a non-whitelisted torrent available on the index.
Adding tags might be a good idea for the last version (not current)
it will be a good idea if it is easy to do
Basically as the title says.
The advantage of this would be that an OpenApi V2 specification can be automatically generated from the code. This would be helpful for those implementing client libraries for Torrust. It should be quite trivial to add too, I'd be more than happy to PR this.
Thanks.
MySQL would be a better default database to use for the index. It has a lot more features than SQLite3 and can handle heavy traffic more efficiently. I think however that we should not yet drop support for SQLite3.
it will be a good idea if it is easy to do
Small Feedback button in case poeple find issue, they can report
Running this command cargo install sqlx-cli
I get this error:
Compiling radix_trie v0.2.1
error: failed to run custom build command for `openssl-sys v0.9.74`
Caused by:
process didn't exit successfully: `/tmp/cargo-install9r6wn4/release/build/openssl-sys-b7846f0d7e417835/build-script-main` (exit status: 101)
--- stdout
cargo:rustc-cfg=const_fn
cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_LIB_DIR
X86_64_UNKNOWN_LINUX_GNU_OPENSSL_LIB_DIR unset
cargo:rerun-if-env-changed=OPENSSL_LIB_DIR
OPENSSL_LIB_DIR unset
cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_INCLUDE_DIR
X86_64_UNKNOWN_LINUX_GNU_OPENSSL_INCLUDE_DIR unset
cargo:rerun-if-env-changed=OPENSSL_INCLUDE_DIR
OPENSSL_INCLUDE_DIR unset
cargo:rerun-if-env-changed=X86_64_UNKNOWN_LINUX_GNU_OPENSSL_DIR
X86_64_UNKNOWN_LINUX_GNU_OPENSSL_DIR unset
cargo:rerun-if-env-changed=OPENSSL_DIR
OPENSSL_DIR unset
cargo:rerun-if-env-changed=OPENSSL_NO_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG
cargo:rerun-if-env-changed=OPENSSL_STATIC
cargo:rerun-if-env-changed=OPENSSL_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_STATIC
cargo:rerun-if-env-changed=PKG_CONFIG_ALL_DYNAMIC
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
run pkg_config fail: "`\"pkg-config\" \"--libs\" \"--cflags\" \"openssl\"` did not exit successfully: exit status: 1\nerror: could not find system library 'openssl' required by the 'openssl-sys' crate\n\n--- stderr\nPackage openssl was not found in the pkg-config search path.\nPerhaps you should add the directory containing `openssl.pc'\nto the PKG_CONFIG_PATH environment variable\nNo package 'openssl' found\n"
--- stderr
thread 'main' panicked at '
Could not find directory of OpenSSL installation, and this `-sys` crate cannot
proceed without this knowledge. If OpenSSL is installed and this crate had
trouble finding it, you can set the `OPENSSL_DIR` environment variable for the
compilation process.
Make sure you also have the development packages of openssl installed.
For example, `libssl-dev` on Ubuntu or `openssl-devel` on Fedora.
If you're in a situation where you think the directory *should* be found
automatically, please open a bug at https://github.com/sfackler/rust-openssl
and include information about your system as well as this message.
$HOST = x86_64-unknown-linux-gnu
$TARGET = x86_64-unknown-linux-gnu
openssl-sys = 0.9.74
', /home/josecelano/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-sys-0.9.74/build/find_normal.rs:191:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: failed to compile `sqlx-cli v0.6.0`, intermediate artifacts can be found at `/tmp/cargo-install9r6wn4`
Caused by:
build failed
21.10
As with any tracker, a RSS feed would be nice to be able to have an easier time grabbing new torrents and seeding them. A separate API key for the feed that's bound to a user and has a long expiration date by default (2mo-6mo) is preferable so as to allow users to just set and forget until the key expires.
There have been quite some database changes between V1 and V2 of the backend and this renders the database of a backend running V1 incompatible with backend V2. The biggest change we made to the database is the way torrents are stored. In V1, torrents were stored as actual .torrent
files in a dedicated uploads folder on the backend server. As of V2, all torrents are completely stored in the database.
To make sure all V1 users can move to V2 of the backend, we want to provide some kind of migration script. This script would take a V1 database (dump) and torrent uploads folder as input and should be able to convert this data to a new database dump that is suitable for the backend V2.
We will start working on this script when we believe V2 is in a usable state.
I've successfully installed the three components of Torrust (tracker, index-backend, index-frontend) and have it all appearing in a client side browser, but can't log in.
My index-backend data.db
has a table torrust_users
which is empty, and I can populate it with data via the command line sqlite3
tool, but don't know how to hash a password correctly to be recognised as valid and let me log in.
Is there a command line tool to do this for me? Alternatively is there a simple openssl
style command to generate the hashed password?
Torrent files are currently uploaded to the uploads
folder. Instead torrents should be completely stored in database tables.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.