Browse Source

Disables tcp harvester if bridge is installed on same machine.

master
damencho 4 years ago
parent
commit
e01d891bba
1 changed files with 15 additions and 2 deletions
  1. 15
    2
      debian/jitsi-meet-web-config.postinst

+ 15
- 2
debian/jitsi-meet-web-config.postinst View File

@@ -48,7 +48,6 @@ case "$1" in
48 48
         if [ -n "$RET" ] && [ "$RET" = "true" ] ; then
49 49
             JVB_SERVE="true"
50 50
         fi
51
-        echo "------> $JVB_SERVE"
52 51
 
53 52
         # stores the hostname so we will reuse it later, like in purge
54 53
         db_set jitsi-meet/jvb-hostname $JVB_HOSTNAME
@@ -106,6 +105,8 @@ case "$1" in
106 105
             sed -i "s/jitsi-meet.example.com/$JVB_HOSTNAME/g" $JITSI_MEET_CONFIG
107 106
         fi
108 107
 
108
+        JVB_CONFIG="/etc/jitsi/videobridge/sip-communicator.properties"
109
+
109 110
         # this is new install let's configure jvb to serve meet
110 111
         # no-nginx, no-apache installed on machine, this is new install or reconfiguring old one which have jvb_serve set
111 112
         if [[ "$JVB_SERVE" = "true" ]] ; then
@@ -113,13 +114,19 @@ case "$1" in
113 114
             echo "------------------------------------------------"
114 115
             echo "You are using jetty to serve jitsi-meet, it is recommended to uninstall(purge) and use default installation that comes with nginx!"
115 116
             echo ""
116
-            echo "When using the following command any custom config will be LOST!!!"
117
+            echo "When using the following command, any custom config will be LOST, please backup /etc/jitsi !!!"
117 118
             echo ""
118 119
             echo "You can purge your installation using the following command:"
119 120
             echo "apt-get purge jitsi-meet jitsi-meet-web-config jitsi-meet-prosody jitsi-meet-web jicofo jitsi-videobridge"
120 121
             echo "------------------------------------------------"
121 122
             echo ""
122 123
         elif [[ "$FORCE_NGINX" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
124
+            # disables tcp harvester to make sure jvb will not take port 443
125
+            if [[ -f $JVB_CONFIG ]] && ! grep -q "org.jitsi.videobridge.DISABLE_TCP_HARVESTER" "$JVB_CONFIG"  ;then
126
+                echo "org.jitsi.videobridge.DISABLE_TCP_HARVESTER=true" >> $JVB_CONFIG
127
+                invoke-rc.d jvb restart || true
128
+            fi
129
+
123 130
             # this is a reconfigure, lets just delete old links
124 131
             if [ "$RECONFIGURING" = "true" ] ; then
125 132
                 rm -f /etc/nginx/sites-enabled/$JVB_HOSTNAME_OLD.conf
@@ -149,6 +156,12 @@ case "$1" in
149 156
 
150 157
             invoke-rc.d nginx reload || true
151 158
         elif [[ "$FORCE_APACHE" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
159
+            # disables tcp harvester to make sure jvb will not take port 443
160
+            if [[ -f $JVB_CONFIG ]] && ! grep -q "org.jitsi.videobridge.DISABLE_TCP_HARVESTER" "$JVB_CONFIG"  ;then
161
+                echo "org.jitsi.videobridge.DISABLE_TCP_HARVESTER=true" >> $JVB_CONFIG
162
+                invoke-rc.d jvb restart || true
163
+            fi
164
+
152 165
             # this is a reconfigure, lets just delete old links
153 166
             if [ "$RECONFIGURING" = "true" ] ; then
154 167
                 a2dissite $JVB_HOSTNAME_OLD.conf

Loading…
Cancel
Save