mirror of
https://github.com/livekit/livekit.git
synced 2026-03-29 17:59:52 +00:00
update ECS deploy to turn on ICE TCP
This commit is contained in:
@@ -4,6 +4,7 @@ locals {
|
||||
rtc = {
|
||||
port_range_start = var.udp_port_start
|
||||
port_range_end = var.udp_port_end
|
||||
ice_tcp_port = var.ice_tcp_port
|
||||
}
|
||||
turn = {
|
||||
enabled = var.turn_enabled
|
||||
@@ -20,7 +21,7 @@ locals {
|
||||
}
|
||||
|
||||
// mapping contains only the main listening ports
|
||||
// other UDP ports don't have to be mapped, due to
|
||||
// other UDP ports don't have to be mapped, due to using host-mode
|
||||
port_mapping = [
|
||||
{
|
||||
containerPort = var.http_port
|
||||
@@ -34,6 +35,10 @@ locals {
|
||||
containerPort = var.turn_udp_port
|
||||
protocol = "udp"
|
||||
},
|
||||
{
|
||||
containerPort = var.ice_tcp_port
|
||||
protocol = "tcp"
|
||||
}
|
||||
]
|
||||
|
||||
task_config = [{
|
||||
|
||||
@@ -80,6 +80,11 @@ variable "udp_port_end" {
|
||||
default = 11000
|
||||
}
|
||||
|
||||
variable "ice_tcp_port" {
|
||||
type = number
|
||||
default = 7881
|
||||
}
|
||||
|
||||
variable "api_keys" {
|
||||
type = map(string)
|
||||
}
|
||||
@@ -91,7 +96,7 @@ variable "redis_address" {
|
||||
|
||||
variable "turn_enabled" {
|
||||
type = bool
|
||||
default = true
|
||||
default = false
|
||||
}
|
||||
|
||||
variable "turn_tcp_port" {
|
||||
|
||||
@@ -15,6 +15,14 @@ resource "aws_security_group" "main" {
|
||||
cidr_blocks = ["0.0.0.0/0"]
|
||||
}
|
||||
|
||||
ingress {
|
||||
description = "TCP port for ICE"
|
||||
from_port = var.ice_tcp_port
|
||||
to_port = var.ice_tcp_port
|
||||
protocol = "tcp"
|
||||
cidr_blocks = ["0.0.0.0/0"]
|
||||
}
|
||||
|
||||
ingress {
|
||||
description = "UDP port for TURN"
|
||||
from_port = var.turn_port_start
|
||||
|
||||
Reference in New Issue
Block a user