From 7b53cd90a287066dfef62cbc6e2ff05efe562a28 Mon Sep 17 00:00:00 2001 From: yomguy Date: Wed, 5 Dec 2012 12:10:15 +0100 Subject: [PATCH] add ROUTER_IP to forward streams --- teleforma/views/core.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/teleforma/views/core.py b/teleforma/views/core.py index 62577044..70cc6c63 100644 --- a/teleforma/views/core.py +++ b/teleforma/views/core.py @@ -416,7 +416,15 @@ class ConferenceRecordView(FormView): context['mime_type'] = 'video/webm' status = Status() status.update() - context['host'] = status.ip + + request_host = get_host(self.request) + local_host = status.ip + if request_host.split('.')[0] == local_host.split('.')[0]: + ip = local_host + else: + ip = settings.ROUTER_IP + + context['host'] = ip context['hidden_fields'] = self.hidden_fields return context -- 2.39.5