Giter Site home page Giter Site logo

Discord integration broken about fireshare HOT 17 CLOSED

Mahh0 avatar Mahh0 commented on July 18, 2024
Discord integration broken

from fireshare.

Comments (17)

J-Stuff avatar J-Stuff commented on July 18, 2024 2

Just as a side note;
If you're running FireShare behind a Reverse proxy and your Domain is protected by Cloudflare. ENSURE CLOUDFLARE CACHING IS DISABLED FOR THE SUBDOMAIN. This has caused me so many hours of wasted time. Especially when troubleshooting Discord not Embedding things properly. This could likely help if you're instance set up behind CF

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024 1

Your link works in the browser but not in discord. And it could be because its not behind https, not sure though since I have no idea how discord handles that.

In the case of mine, I have my reverse proxy set up to forward all http traffic to https. So even if you put it discord as http, it will be forwarded to https.

I would try to get yours setup behind https which you could do by using letsencrypt to get yourself an ssl certificate.

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024 1

@Mahh0 yes you are correct.

Fireshare by itself uses only http, but you have https setup between nginx (i.e nginxproxymanager) and your end user. Nginx then forwards that decrypted traffic from the end user on https to your fireshare container listening on http.

This is fine because nginx and fireshare should be running on the same machine. You want the traffic from outside your machine/server to be encrypted.

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024 1

I am going to consider this issue resolved.

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024

image

I tested this just now on the latest version and it is working as intended for me on Discord. Either it is an issue with discord or an issue with your video file itself or potentially your reverse proxy setup around Fireshare. Make sure your videos are h264 encoded.

All I can say is that it is not an issue with Fireshare.

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

I don't understand... I tried with my own file and also a downloaded youtube video that I just converted to H264 using handbrake but it's still not working ..
I don't have a reverse proxy setup.
The container is run on a raspberry pi, can't that be because of this ?

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024

Fireshare needs to be web accessible for your links in discord to work. They might still work for you if your running fireshare locally but anybody you send the clips too is not going to be able to play them unless your fireshare instance is web accessible under a domain name.

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

it is web accessible, we can see it with the thumbnail showing ..

Docker-compose
version: "3"
services:
fireshare:
container_name: fireshare
image: shaneisrael/fireshare:latest
ports:
- "8080:80"
volumes:
- /srv/fireshare/data:/data
- /srv/fireshare/processed:/processed
- /srv/fireshare/videos:/videos
environment:
- ADMIN_USERNAME=admin
- ADMIN_PASSWORD=hidden
- SECRET_KEY=hidden
- MINUTES_BETWEEN_VIDEO_SCANS=5
- PUID=1012
- PGID=1012

Router (8080 IN / 80 OUT)
image

The web server is accessible from the outside using my DDNS. When going on the website, the video is playable but not using discord integration (from my home network AND from outside)

I've tried running the container on a windows computer to eliminate a raspberry pi problem, but I still have the same issue

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024

I'm not sure what to say then. It's not an issue in Fireshare as every single one of my videos plays in discord just fine. You click play and you might have to wait 2-3 seconds but the video does end up playing.

You can test this yourself. Paste this that I'm about to link you into your discord server and it should play no problem. This specific video is very large in file size, but it will play so long as your download speed is decent.

https://v.fireshare.net/w/396cbfca399a9888b423deb3e6f4481e

Also make sure you are posting the "share" links in your discord server. They should be .../w/ NOT .../#/w/. Links with the # in them will not play in discord or other apps.

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024

You can get the share link by clicking on any of the share links in fireshare.
image
image

But if you are copying the link directly from the browser url bar you are getting the .../#/w/ link which will not work.

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

That's what I'm doing, I'm having http://mydomain/w/20d04ff5ebbaafa5a29ab3fb4810

There is something I'm missing but I can't find what..

from fireshare.

Shane-stage avatar Shane-stage commented on July 18, 2024

Did you try my link? Does my link work in your discord server?

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

Yes, it works with your link. I tried on several servers and double checked my account settings.

I thought it might come from discord which could block HTTP but your link works with HTTP and HTTPS

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

does that works for you ? : http://maho.ddns.net/w/4eea20d04ff5ebbaafa5a29ab3fb4810

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

Just tested with HTTPS on my windows docker desktop environment and it's working ! It looks like it was the issue...
Tysm for the help, I will now have fun with fireshare

I added the following in /etc/nginx/nginx.conf

listen 443 ssl default_server;
listen [::]:443 ssl default_server;

And then ran the following command to create the certficiate and update nginx conf :

certbot --nginx -d maho.ddns.net

I selected an option to redirect http to https so that makes http access also work

Now I need to find a definitive solution, I don't really know how docker and nginx works but if my container is restarted, or updated I will loose everything ..

So maybe I can set the cerbot and the nginx file and my host os and specify them as files in the docker-compose ? Or maybe update the docker file ?

from fireshare.

ShaneIsrael avatar ShaneIsrael commented on July 18, 2024

You can create a volume map with docker which will map a directory on your machine into the docker container. Then any files saved to that location in the docker container will exist on your machine so that if you reset the docker container you don't lose those files. (i.e the nginx conf files and letsencrypt certs).

Personally, if you want a minimal setup that "just works" I would use Nginx Proxy Manager.

https://nginxproxymanager.com/guide/#quick-setup

Has a very simple docker setup with a volume map so that your configs are not lost. Provides a very nice and intuitive user interface to create your proxy host, and will create yours ssl certificate via letsencrypt for you.

from fireshare.

Mahh0 avatar Mahh0 commented on July 18, 2024

Can you give me an example of configuration please ?

If I understand, fireshare is configured to work only with HTTP and HTTPS is between nginx proxy manager and user ? Sorry but i don't understand well reverse proxy

from fireshare.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.