microscopic-dress-75199
09/23/2025, 6:05 PMservices:
redis:
image: redis
volumes:
- redis_data:/data
ports:
- 6379:6379
# The following line might be uncommented to run on MacOS
# for testing and development purposes only.
network_mode: host
livekit:
image: livekit/livekit-server
command: --config /etc/livekit.yaml
network_mode: host
volumes:
- ./livekit.yaml:/etc/livekit.yaml
depends_on:
redis:
condition: service_started
sip:
image: livekit/sip
network_mode: host
environment:
SIP_CONFIG_BODY: |
api_key: 'devkey'
api_secret: 'secret'
ws_url: '<ws://localhost:7880>'
redis:
address: 'localhost:6379'
sip_port: 5060
rtp_port: 10000-20000
use_external_ip: true
logging:
level: debug
volumes:
redis_data:tall-airline-16756
09/23/2025, 6:05 PMtall-airline-16756
09/23/2025, 6:06 PMlivekit/generate Docker image! It's thoughtfully designed to help you set up a complete, production-ready LiveKit environment. On the other hand, the docker-compose.yaml file you have is usually geared towards local testing or development. Let me walk you through the main differences to make things clearer:
• Purpose: The livekit/generate image helps you create a deployment-ready package with domain-specific configurations tailored for production, while docker-compose.yaml offers a simpler setup intended for local use.
• Components: With livekit/generate, you get Caddy included, which automatically manages HTTPS and secure connections. In contrast, docker-compose.yaml doesn’t include this and usually runs in a less secure development mode.
• Deployment Automation: The livekit/generate setup comes with handy scripts that automate deployment on cloud platforms or Linux VMs, making your life easier. The docker-compose.yaml file, however, requires you to run things manually.
• Additional Features: If you’re interested in LiveKit Ingress and Egress, livekit/generate supports optional setup for these, while the basic docker-compose.yaml doesn’t include them.
To sum it up, if you’re aiming for a secure, production-ready deployment, livekit/generate is a great choice. But if you just want to experiment or test things locally, docker-compose.yaml will do the job nicely. I hope this helps clarify things! Feel free to ask if you want to dive deeper into any part.
Sources: Deploy to a VM | LiveKit Docs | test/integration/livekit_test.gomicroscopic-dress-75199
09/23/2025, 6:12 PMtall-airline-16756
09/23/2025, 6:13 PMmicroscopic-dress-75199
09/23/2025, 6:15 PMsip:
image: livekit/sip
network_mode: host
environment:
SIP_CONFIG_BODY: |
api_key: 'devkey'
api_secret: 'secret'
ws_url: '<ws://localhost:7880>'
redis:
address: 'localhost:6379'
sip_port: 5060
rtp_port: 10000-20000
use_external_ip: true
logging:
level: debug
3. I am building for production now.tall-airline-16756
09/23/2025, 6:16 PMlivekit/sip image in production:
• TURN Server: While a TURN server isn’t absolutely required for SIP-based telephony, it’s mainly helpful for WebRTC clients behind strict firewalls—not for SIP signaling or RTP media traffic. If your LiveKit participants (like web or mobile clients) are behind firewalls, you might want to enable TURN in the LiveKit server configuration to help them connect smoothly.
• SIP Server Configuration: The livekit/sip image works as a bridge between SIP telephony and LiveKit rooms. You can set it up using the SIP_CONFIG_BODY environment variable or a configuration file. Just be sure to include your API key, WebSocket URL, Redis address, and the public IP for SIP and RTP ports to keep everything running seamlessly.
• Production Setup: For the best performance and to avoid port-mapping headaches, run the SIP service with --network host. Also, make sure your firewall allows UDP ports 5060 (for SIP) and 10000–20000 (for RTP) to keep calls flowing smoothly.
• Additional Steps: Don’t forget to use the LiveKit CLI to create SIP trunks and dispatch rules, which help route calls properly to your LiveKit rooms.
If you’d like me to walk you through any of these steps in more detail, just let me know—I’m here to help!
Sources: pkg/sip/server.go | Deploying LiveKit | LiveKit Docs | Ports and firewall | LiveKit Docsmicroscopic-dress-75199
09/23/2025, 6:18 PMtall-airline-16756
09/23/2025, 6:18 PMlivekit/generate isn’t absolutely necessary. It’s mainly designed to help create a complete, production-ready LiveKit deployment, including HTTPS and domain-specific configurations. Since you’re focusing on telephony and already using the livekit/sip image, you’re perfectly fine to proceed without it if you:
• Manually configure the SIP server and LiveKit server as we discussed earlier.
• Make sure your networking is set up properly, including opening the necessary ports (5060 for SIP and 10000–20000 for RTP).
• Set up your SIP trunks and dispatch rules to handle call routing.
If you’d rather have an automated deployment with extra features like HTTPS and domain setup, livekit/generate is still a great starting point. Just keep in mind you’ll need to add the SIP server configuration manually since it’s not included by default.
Please feel free to reach out if you’d like me to clarify anything or help you further—I’m here to support you!
Sources: Integrating with Telephony | LiveKit Docs | SIP Integration | livekit/livekit_composite | DeepWiki | LiveKit SDKs Overview | LiveKit Docs | OpenAI and LiveKit partner to turn Advanced Voice into an API | OpenAI and LiveKit partner to turn Advanced Voice into an API