LiveSwitch Gateway releases.
100K+
The LiveSwitch Gateway authorizes access to LiveSwitch and provides the central message brokering service on which other LiveSwitch services rely.
Do the following:
sudo docker network create liveswitch
sudo docker run -d \
--network liveswitch \
--publish 6379:6379 \
--restart always \
--name redis \
redis
sudo docker run -d \
--env POSTGRES_PASSWORD='password' \
--network liveswitch \
--publish 5432:5432 \
--restart always \
--name postgres \
postgres
sudo docker run -d \
--network liveswitch \
--publish 5672:5672 \
--publish 15672:15672 \
--restart always \
--name rabbitmq \
rabbitmq:3-management
sudo docker exec -it postgres \
psql "postgresql://postgres:password@localhost" -c "CREATE DATABASE recording;"
sudo docker exec -it postgres \
psql "postgresql://postgres:password@localhost" -c "GRANT ALL PRIVILEGES ON DATABASE recording TO postgres;"
sudo docker run -d \
--env CONNECTIONSTRINGS:DEFAULT='postgres://postgres:password@postgres:5432/postgres' \
--env CONNECTIONSTRINGS:CACHE='redis://redis' \
--network liveswitch \
--publish 8080:8080 \
--publish 9090:9090 \
--publish 8443:8443 \
--publish 9443:9443 \
--restart always \
--name liveswitch-gateway \
frozenmountain/liveswitch-gateway
sudo docker run -d \
--env CONNECTIONSTRINGS:DEFAULT='postgres://postgres:password@postgres:5432/postgres' \
--env CONNECTIONSTRINGS:CACHE='redis://redis' \
--env Deployments:0:DeploymentId='Default' \
--env Deployments:0:RecordingManagement:Enabled='true' \
--env Deployments:0:RecordingManagement:AmqpUri='amqp://guest:guest@rabbitmq:5672' \
--env Deployments:0:RecordingManagement:PostgresUri='postgres://postgres:password@postgres:5432/recording' \
--network liveswitch \
--publish 8080:8080 \
--publish 9090:9090 \
--publish 8443:8443 \
--publish 9443:9443 \
--restart always \
--name liveswitch-gateway \
frozenmountain/liveswitch-gateway
See below for more information about the CONNECTIONSTRINGS:DEFAULT and CONNECTIONSTRINGS:CACHE environment variables.
/sync on TCP port 8080 handles HTTP and WebSocket signalling traffic from client applications, LiveSwitch Media Servers, and LiveSwitch SIP Connectors. TCP port 8443 is optionally available for TLS termination (HTTPS) if a certificate is provided.
/admin on TCP port 9090 handles HTTP administration traffic from the console and REST API. TCP port 9443 is optionally available for TLS termination if a certificate is provided.
The LiveSwitch Gateway has two levels of configuration.
Environment variables are recommended for instance configuration. Note that this configuration is specific to the particular Gateway in the container.
If using a JSON file, it must be located at /app/FM.LiveSwitch.Gateway.Service.config.json, e.g.:
docker cp FM.LiveSwitch.Gateway.Service.config.json liveswitch-gateway:/app/FM.LiveSwitch.Gateway.Service.config.json
Example JSON file:
{
"ConnectionStrings": {
"Default": "postgres://postgres:password@postgres:5432/postgres",
"Cache": "redis://redis"
},
"TrustedServerCertificateSha1Fingerprints": [],
"Admin": {
"IPAddresses": []
},
"Sync": {
"IPAddresses": []
}
}
Environment variable names map to the JSON property names using .NET Core conventions.
CONNECTIONSTRINGS:DEFAULTA postgres connection URI that matches the documentation here. If not provided, the server will fail to startup.
CONNECTIONSTRINGS:CACHEA redis connection string compatible with ServiceStack.Redis. If not specified, it will default to 127.0.0.1.
TRUSTEDSERVERCERTIFICATESHA1FINGERPRINTSA list of SHA-1 fingerprints (hexadecimal, no colons, case insensitive) from trusted certificates used by the redis data access layer, i.e. when redis traffic is encrypted and the redis server is using a self-signed TLS certificate.
ADMIN:IPADDRESSESThe IP address(es) or CIDR range(s) for the administration (default port 9090) service binding. If not specified, all network interfaces will be used.
SYNC:IPADDRESSESThe IP address(es) or CIDR range(s) for the signalling (default port 8080) service binding. If not specified, all network interfaces will be used.
To learn how to configure your cluster, see Cluster Configuration.
To learn how to configure your application, see Application Configuration.
Content type
Image
Digest
sha256:b46d372f3…
Size
133.9 MB
Last updated
about 2 months ago
docker pull frozenmountain/liveswitch-gateway