OpenIM Chat uses the LiveKit server as the media server to support video calls and video meeting services.
LiveKit is an open-source WebRTC SFU written in Go, built on top of the excellent Pion project. For more information, visit the LiveKit website.
To self-host LiveKit, start the server with the following Docker command:
replace
your-server-ip
with your server IP address
docker run -d \
-p 7880:7880 \
-p 7881:7881 \
-p 7882:7882/udp \
-v $PWD/livekit/livekit.yaml:/livekit.yaml \
livekit/livekit-server \
--config /livekit.yaml \
--bind 0.0.0.0 \
--node-ip=your-server-ip
To check the server logs and ensure everything is running correctly, use the following command:
docker logs livekit/livekit-server
Update the config/chat-rpc-chat.yml
file to configure the LiveKit server address:
liveKit:
url: "ws://127.0.0.1:7880" # LIVEKIT_URL, LiveKit server address and port
By following these steps, you can set up and configure the LiveKit server for use with OpenIM Chat.
For detailed instructions on deploying LiveKit, refer to the self-hosting deployment documentation.