可以调整livekit前端sdk,不使用ice的执行结果,使用livekit的内网ip+端口推拉流吗...
# ask-ai
a
可以调整livekit前端sdk,不使用ice的执行结果,使用livekit的内网ip+端口推拉流吗?给出代码示例
t
Thanks for reaching out, 徐旭. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
To configure the LiveKit frontend SDK to use an internal IP and port for streaming instead of ICE results, you need to adjust the LiveKit server's configuration. Here's how you can do it: 1. Update the RTC Configuration in `livekit.yaml`:
Copy code
rtc:
  use_external_ip: false  # Disable external IP discovery
  node_ip: "192.168.1.100"  # Internal IP to use
  tcp_port: 7881          # TCP port for ICE connections
Explanation: • `use_external_ip`: Set to
false
to disable external IP discovery. • `node_ip`: Specify the internal IP address for LiveKit to use. • `tcp_port`: Define the TCP port for ICE connections when UDP is unavailable. 2. Ensure Proper Port Configuration: • Open the specified TCP port (e.g., 7881) in your firewall. • If behind a NAT or firewall, ensure the internal IP and port are correctly mapped to the public-facing IP and port if needed. Let me know if you need further assistance or clarification!
a
node_ip必须配置为公网ip使用,我想修改前端sdk让政务外网的用户直连livekit内网ip,互联网用户直连公网ip
t
I don't have the answer you're looking for. You could also try asking your question: • in one of the other Slack channels or • to https://deepwiki.com/livekit/livekit_composite which is trained on all LiveKit source code If you find the answer, please post it here to help others!