Chihaya torrent tracker on Heroku.
Chihaya HTTP torrent tracker tunneled from a worker dyno using Cloudflare Tunnel client.
As worker dyno do not sleep on free dyno, and in order not to put strain on Heroku's HTTP routers.
You need Heroku CLI and a configured Cloudflare Tunnel.
- Clone this repository.
- Create an app on Heroku.
- Encode the Cloudflare Tunnel JSON credential in Base64 using this command
base64 -w 0 <cloudflare-tunnel-id>.json
. - Set Cloudflare Tunnel configuration encoded in Base64 on config vars
heroku config:set CLOUDFLARE_TUNNEL_CREDENTIAL=<cloudflare-tunnel-credential-base64>
. - Encode the Cloudflare Tunnel config.yaml in Base64 using this command
base64 -w 0 config.yaml
. - Set Cloudflare Tunnel config.yaml encoded in Base64 on config vars
heroku config:set CLOUDFLARE_TUNNEL_CONFIGURATION=<cloudflare-tunnel-config.yaml-base64>
.
- Set git remote to Heroku
heroku git:remote -a your-app-name
. - Set stack to container
heroku stack:set container -a your-app-name
. - Deploy to Heroku
git push heroku main
.
You need Docker.
- Build the image and push to Container Registry
heroku container:push web -a your-app-name
. - Release the image
heroku container:release web
.
url: http://localhost:6969
tunnel: deadbeef-1234-4321-abcd-123456789abc
credentials-file: /app/cloudflare-tunnel-credential.json
With Metrics:
tunnel: deadbeef-1234-4321-abcd-123456789abc
credentials-file: /app/cloudflare-tunnel-credential.json
ingress:
- hostname: tracker.example.com
service: http://localhost:6969
- hostname: tracker-metrics.example.com
service: http://localhost:8080
- service: http_status:404