Home

Awesome

<p align="center"> <img src="https://github.com/Rhilip/RidPT/raw/master/public/static/pic/logo.png" width='256px'><br/> Another Private Torrent framework Project. <b>On Heavily Development now !!!</b><br/> </p>

Codacy Badge GitHub Releases used-Swoole-blue GitHub license FOSSA Status Telegram Group


Demo Site

Demo Url: https://ridpt.top/

Test Account Information:

Installation Guide

  1. We test our RidPT project on this environment :

  2. After you prepare those base environment well

    • run below command to clone this repo or you can download from our release.
      git clone https://github.com/Rhilip/RidPT.git /home/wwwroot/your.domain.com
      cd /home/wwwroot/your.domain.com/
      
    • Use composer install to install PHP dependency.
    • Use bower install to install our front-end dependency (like js,css,font)
    • If you don't run RidPT apps in root user, you should give enough permission to apps/{storage,var}.
  3. Import Database Structure from our migration/ridpt.sql, and disable Mysql strict mode NO_ZERO_IN_DATE and NO_ZERO_DATE.

    mysql -u root -p < migration/ridpt.sql
    
  4. Then set your RidPT Project config (about APP, DATABASE, Redis, Mailer) in .env (Or better .env.local). The other config about site your can edit in Admin Panel.

    cp .env.example .env
    vi .env
    
  5. Run Test by php bin/console server start -u , And Congratulation If you see those output without error throwout.

    root@Ubuntu-iso-DND:/data/wwwroot/ridpt.top# php bin/console server:start
    
       ____            __  ____    ______                                                                                   
      /\  _`\   __    /\ \/\  _`\ /\__  _\                                                                                  
      \ \ \L\ \/\_\   \_\ \ \ \L\ \/_/\ \/                                                                                  
       \ \ ,  /\/\ \  /'_` \ \ ,__/  \ \ \                                                                                  
        \ \ \\ \\ \ \/\ \L\ \ \ \/    \ \ \                                                                                 
         \ \_\ \_\ \_\ \___,_\ \_\     \ \_\                                                                                
          \/_/\/ /\/_/\/__,_ /\/_/      \/_/                                                                                
    
     ------------------------ ------------------------------------------------ 
      Environment              Value                                           
     ------------------------ ------------------------------------------------ 
      System      Name         Linux                                           
      Framework   Version      v0.1.7-alpha                                    
      PHP         Version      7.4.1                                           
      Swoole      Version      4.4.14                                          
      Listen      Addr         127.0.0.1                                       
      Listen      Port         9501                                            
      Reactor     Num          1                                               
      Worker      Num          5                                               
      Hot         Update       disabled                                        
      Coroutine   Mode         disabled                                        
      Config      File         /data/wwwroot/ridpt.top/config/application.php  
     ------------------------ ------------------------------------------------ 
    
  6. Then you can safely add Nginx reserve proxy config like migration/nginx.conf. And Notice : If your service is behind the CDN like Cloudflare, You MUST follow How do I restore original visitor IP with Nginx? So that tracker can correctly record the peer's ip address.

  7. Use the default php bin/console server:start -d to let RidPT RUN in the background. Or you can use other daemon work like:

Basie Environment Setting in .env

Notice: Any change in file .env require the restart of Application to Make it effective

Section APP

Document: None

KeyTypeNote
APP_ENVENUM('local','staging')Not use now.
APP_DEBUGBoolTurn on or off the debug model,Turn if off after success deploy !
APP_SECRET_KEYStringThe key used to encrypt and decrypt some data.(Change it before deploy and don't Change it after Deploy)
APP_SECRET_IVStringA non-NULL Initialization Vector.(Change it before deploy and don't Change it after Deploy)

Section Database

Document: PHP: PDO::__construct - Manual

KeyTypeNote
DATABASE_DSNDSNThe Data Source Name, or DSN, contains the information required to connect to the database.
DATABASE_USERNAMEStringThe user name for the DSN string.
DATABASE_PASSWORDStringThe password for the DSN string.

Section Redis

Document: phpredis/phpredis

KeyTypeNote
REDIS_HOSTStringA host, or the path to a unix domain socket.
REDIS_PORTIntDy default 6379.
REDIS_DATABASEIntdbindex, the database number to switch to.
REDIS_PASSWORDStringThe password for the Redis server.

Section Mailer

Document: the PHPMailer wiki

KeyTypeNote
MAILER_DEBUGIntSMTP class debug output mode.
MAILER_HOSTStringSMTP hosts.
MAILER_PORTIntThe default SMTP server port.
MAILER_ENCRYPTIONEnum('','tls','ssl')What kind of encryption to use on the SMTP connection.
MAILER_USERNAMEStringSMTP username.
MAILER_PASSWORDStringSMTP password.
MAILER_FROMStringThe from address of this email.
MAILER_FROMNAMEStringThe from name of this email.

Dynamic Config

Notice: Most Dynamic config note you can found in our config setting Page

// TODO

Development Help

Some rule or Docs May help you when you rebuild this project, Or you can join our chat group on Telegram -- @ridpt

FrontEnd

LibraryDocs
Zui: an HTML5 front UI frameworkhttp://zui.sexy/ ( Chinese Version )
FortAwesome: The iconic SVG, font, and CSS toolkithttps://fontawesome.com/icons?d=gallery
flag-css: CSS for SVG country flags respecting the original ratio.https://kfpun.com/flag-css/
zxcvbn: Low-Budget Password Strength Estimationhttps://lowe.github.io/tryzxcvbn/
bootstrap-validator: A user-friendly HTML5 form validation jQuery plugin for Bootstrap 3http://1000hz.github.io/bootstrap-validator
jQuery.Textarea.Autoresize: Smart resizing for textareas using jQueryhttps://github.com/AndrewDryga/jQuery.Textarea.Autoresize

Backend Library

LibraryUsed AsDocs
MixPHP v1Frameworkhttps://www.kancloud.cn/onanying/mixphp1/379324 ( Chinese Version )
vlucas/phpdotenvphpdotenvhttps://github.com/vlucas/phpdotenv
adhocore/cliConsole Applicationhttps://github.com/adhocore/php-cli
siriusphp/validationValidatorhttp://www.sirius.ro/php/sirius/validation/
league/platesTemplate systemhttp://platesphp.com/
firebase/php-jwtJWThttps://github.com/firebase/php-jwt, https://jwt.io/

Sponsor

MeiHeZi For Demo Site Host Server

License

FOSSA Status