coollabsio / coolify

An open-source & self-hostable Heroku / Netlify / Vercel alternative.
https://coolify.io
Apache License 2.0
26.28k stars 1.33k forks source link

[Feature]: Jitsi Meet Template #2304

Open RayBB opened 1 month ago

RayBB commented 1 month ago

Description

I would like a template for Jitsi Meet merged into this Coolify repo.

Generally, feature requests don't go in issue they go in discussion (like I posted with details in https://github.com/coollabsio/coolify/discussions/2197) but I want to set a bounty on this so I'm making it an issue.

If you can get a Jitsi meet template working and merged I consider then the bounty is complete.

PS: I tried to get this working myself but ran into issues with exposing the ports. I suspect this shouldn't be too hard to resolve for someone who has setup Jitsi before.

Minimal Reproduction (if possible, example repository)

n/a

Exception or Error

No response

Version

n/a

algora-pbc[bot] commented 1 month ago

💎 $10 bounty • Ray Berger

💎 $30 bounty • CloudGakkai

Steps to solve:

  1. Start working: Comment /attempt #2304 with your implementation plan
  2. Submit work: Create a pull request including /claim #2304 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

Thank you for contributing to coollabsio/coolify!

Add a bounty • Share on socials

Attempt Started (GMT+3) Solution
🟢 @LEstradioto Jun 4, 2024, 9:55:04 AM #2348
LEstradioto commented 1 month ago

/attempt #2304

I will PR shortly

This is a tricky template. Some notes here:

that said, using Traefik, on Server > Proxy > Configuration, we must edit PORTS and ADD Traefik entryPoints, eg.:

version: '3.8'
networks:
  coolify:
    external: true
services:
  traefik:
    container_name: coolify-proxy
    image: 'traefik:v2.10'
    restart: unless-stopped
    extra_hosts:
      - 'host.docker.internal:host-gateway'
    networks:
      - coolify
    ports:
      - '80:80'
      - '443:443'
      - '8080:8080'
         # This line maps UDP port 10000 on the host to the container
      - '10000:10000/udp'
    healthcheck:
      test: 'wget -qO- http://localhost:80/ping || exit 1'
      interval: 4s
      timeout: 2s
      retries: 5
    volumes:
      - '/var/run/docker.sock:/var/run/docker.sock:ro'
      - '/data/coolify/proxy:/traefik'
    command:
      - '--ping=true'
      - '--ping.entrypoint=http'
      - '--api.dashboard=true'
      - '--api.insecure=false'
      - '--entrypoints.http.address=:80'
      - '--entrypoints.https.address=:443'
      - '--entrypoints.http.http.encodequerysemicolons=true'
      - '--entryPoints.http.http2.maxConcurrentStreams=50'
      - '--entrypoints.https.http.encodequerysemicolons=true'
      - '--entryPoints.https.http2.maxConcurrentStreams=50'
      # This line configures Traefik entrypoints to work with Jitsi template and listen on UDP port 10000
      - '--entryPoints.video.address=:10000/udp'
      - '--providers.docker.exposedbydefault=false'
      - '--providers.file.directory=/traefik/dynamic/'
      - '--providers.file.watch=true'
      - '--certificatesresolvers.letsencrypt.acme.httpchallenge=true'
      - '--certificatesresolvers.letsencrypt.acme.storage=/traefik/acme.json'
      - '--certificatesresolvers.letsencrypt.acme.httpchallenge.entrypoint=http'
      - '--providers.docker=true'
    labels:
      - traefik.enable=true
      - traefik.http.routers.traefik.entrypoints=http
      - traefik.http.routers.traefik.service=api@internal
      - traefik.http.services.traefik.loadbalancer.server.port=8080
      - coolify.managed=true

In my case, I also needed to open port 10000 in AWS Firewall.

I don't think it's possible to configure these Traefik settings on the fly using only template or Dynamic Configuration. I couldn't do it but it would simplify Jitsi setup. Perhaps with Caddy, however, it wouldn't be explicit about what's happening to the user.

LEstradioto commented 1 month ago

It would be nice if someone reviews it, since you tried to implement before, can you try it? @RayBB

DeVoresyah commented 1 month ago

wow, you're mvp bro @LEstradioto. Could you also check this? #2346

RayBB commented 3 weeks ago

How do you try it with the .env file? Do I have to manually set those variables somewhere in coolify?

LEstradioto commented 3 weeks ago

Ive setup the minimal setup. You can add it more env vars at

image /project/xxx/production/application/xxx#environment-variables

Jitsi has plenty of environment variables I could add all of them in blank, would that be better?